diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000..ad0ecf78e --- /dev/null +++ b/.gitignore @@ -0,0 +1,31 @@ +/.idea +sprint_1/package-lock.json +node_modules/ +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +pnpm-debug.log* +lerna-debug.log* + +node_modules + +sprint_1/node_modules +dist +dist-ssr +*.local + +# Editor directories and files +.vscode/* +!.vscode/extensions.json +.idea +.DS_Store +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? +package-lock.json + diff --git a/README.md b/README.md index bcd1a1367..b19910416 100644 --- a/README.md +++ b/README.md @@ -1,83 +1,18 @@ -### Ветка, в которой делаете задания спринта, должна называться sprint_i, где i - номер спринта. Не переименовывайте её. - -### Откройте pull request в ветку main из ветки, где вы разрабатывали проект, и добавьте ссылку на этот pr в README.md в ветке main. -### ВАЖНО: pull request должен называться “Sprint i” (i — номер спринта). - -### Например, задания для проектной работы во втором спринте вы делаете в ветке sprint_2. Открываете из неё pull request в ветку main. Ссылку на этот pr добавляете в README.md в ветке main. После этого на платформе Практикума нажимаете «Проверить задание». - -### Также не забудьте проверить, что репозиторий публичный. ---- - - -Даже законченный проект остаётся только заготовкой, пока им не начнут пользоваться. Но сначала пользователь должен понять, зачем ему пользоваться вашим кодом. В этом помогает файл README. - -README — первое, что прочитает пользователь, когда попадёт в репозиторий на «Гитхабе». Хороший REAMDE отвечает на четыре вопроса: - -- Готов ли проект к использованию? -- В чём его польза? -- Как установить? -- Как применять? - -## Бейджи - -Быстро понять статус проекта помогают бейджи на «Гитхабе». Иногда разработчики ограничиваются парой бейджев, которые сообщат о статусе тестов кода: - -![Бэйджи](https://github.com/yandex-praktikum/mf.messenger.praktikum.yandex.images/blob/master/mf/b.png) - -Если пользователь увидит ошибку в работе тестов, то поймёт: использовать текущую версию в важном проекте — не лучшая идея. - -Бейджи помогают похвастаться достижениями: насколько популярен проект, как много разработчиков создавало этот код. Через бейджи можно даже пригласить пользователя в чат: - -![Версии](https://github.com/yandex-praktikum/mf.messenger.praktikum.yandex.images/blob/master/mf/vers.png) - -В README **Webpack** строка бейджев подробно рассказывает о покрытии кода тестами. Когда проект протестирован, это вызывает доверие пользователя. Последний бейдж приглашает присоединиться к разработке. - -Другая строка убедит пользователя в стабильности инфраструктуры и популярности проекта. Последний бейдж зовёт в чат проекта. - -## Описание - -Краткое опишите, какую задачу решает проект. Пользователь не верит обещаниям и не готов читать «полотна» текста. Поэтому в описании достаточно нескольких строк: - -![Описание](https://github.com/yandex-praktikum/mf.messenger.praktikum.yandex.images/blob/master/mf/desc.png) - -Авторы **React** дробят описание на абзацы и списки — так проще пробежаться глазами по тексту и найти ключевую информацию. - -Если у проекта есть сайт, добавьте ссылку в заголовок. - -## Установка - -Лучше всего пользователя убеждает собственный опыт. Чем быстрее он начнёт пользоваться проектом, тем раньше почувствует пользу. Для этого помогите ему установить приложение: напишите краткую пошаговую инструкцию. - -Если проект предназначен для разработчиков, добавьте информацию об установке тестовых версий. Например: - -- `npm install` — установка стабильной версии, -- `npm start` — запуск версии для разработчика, -- `npm run build:prod` — сборка стабильной версии. - -## **Примеры использования** - -Хорошо, если сразу после установки пользователь сможет решить свои задачи без изучения проекта. Это особенно верно, если ваш пользователь — не профессиональный разработчик. Но даже профессионал поймёт вас лучше, если показать примеры использования: - -![Ссылки](https://github.com/yandex-praktikum/mf.messenger.praktikum.yandex.images/blob/master/mf/link.png) - -Для более подробных инструкции добавьте новые разделы или ссылки: - -- на документацию, -- вики проекта, -- описание API. - -В учебном проекте будут полезен раздел с описанием стиля кода и правилами разработки: как работать с ветками, пул-реквестами и релизами. - -### **Команда** - -Если вы работаете в команде, укажите основных участников: им будет приятно, а новые разработчики охотнее присоединятся к проекту. «Гитхаб» — не просто инструмент, это социальная сеть разработчиков. - -![Команда](https://github.com/yandex-praktikum/mf.messenger.praktikum.yandex.images/blob/master/mf/team.png) - -### **Примеры README** - -- «[Реакт](https://github.com/facebook/react)», -- «[Эхо](https://github.com/labstack/echo)», -- «[Вебпак](https://github.com/webpack/webpack)», -- «[ТДенгине](https://github.com/taosdata/TDengine)», -- «[Соул-хантинг](https://github.com/vladpereskokov/soul-hunting/)». +# Онлайн мессенджер +## sprint 1 + +### Используется изменённый шаблон - [Figma template](https://www.figma.com/file/X8GNQmK02psoAq2MfGR9Qp/Chat_external_link-(Copy)?type=design&node-id=0-1&mode=design&t=fByee93OCMjQCrxW-0) + +## Основные страницы чата +1. [Авторизация](https://playful-naiad-496831.netlify.app/) +1. [Регистрация](https://playful-naiad-496831.netlify.app/register) +1. [Чаты](https://playful-naiad-496831.netlify.app/messages) +1. [Профиль](https://playful-naiad-496831.netlify.app/profile) +1. [Профиль - редактирование](https://playful-naiad-496831.netlify.app/profile-edit) +1. [Профиль - редактирование - пароль](https://playful-naiad-496831.netlify.app/profile-edit-password) +1. [500](https://playful-naiad-496831.netlify.app/500) +1. [404](https://playful-naiad-496831.netlify.app/404) + +## Команды +### Установка проекта - `npm install` +### Запуск проекта - `npm run start` \ No newline at end of file diff --git a/netlify.toml b/netlify.toml new file mode 100644 index 000000000..ce86dd3d8 --- /dev/null +++ b/netlify.toml @@ -0,0 +1,19 @@ +# Global settings applied to the whole site. +# +# “base” is the directory to change to before starting build. If you set base: +# that is where we will look for package.json/.nvmrc/etc, not repo root! +# “command” is your build command. +# “publish” is the directory to publish (relative to the root of your repo). + +[build] + command = "npm run build" + publish = "dist" + +[context.production] + command = "npm run build" + publish = "dist" + +[[redirects]] + from = "/*" + to = "/index.html" + status = 200 \ No newline at end of file diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 000000000..e34636403 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,1458 @@ +{ + "name": "sprint_1", + "version": "0.0.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "sprint_1", + "version": "0.0.0", + "dependencies": { + "express": "^4.18.2", + "lodash-es": "^4.17.21", + "vite-plugin-handlebars": "^2.0.0" + }, + "devDependencies": { + "handlebars": "^4.7.8", + "vite": "^5.0.8" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.19.12.tgz", + "integrity": "sha512-bmoCYyWdEL3wDQIVbcyzRyeKLgk2WtWLTWz1ZIAZF/EGbNOwSA6ew3PftJ1PqMiOOGu0OyFMzG53L0zqIpPeNA==", + "cpu": [ + "ppc64" + ], + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.19.12.tgz", + "integrity": "sha512-qg/Lj1mu3CdQlDEEiWrlC4eaPZ1KztwGJ9B6J+/6G+/4ewxJg7gqj8eVYWvao1bXrqGiW2rsBZFSX3q2lcW05w==", + "cpu": [ + "arm" + ], + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.19.12.tgz", + "integrity": "sha512-P0UVNGIienjZv3f5zq0DP3Nt2IE/3plFzuaS96vihvD0Hd6H/q4WXUGpCxD/E8YrSXfNyRPbpTq+T8ZQioSuPA==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.19.12.tgz", + "integrity": "sha512-3k7ZoUW6Q6YqhdhIaq/WZ7HwBpnFBlW905Fa4s4qWJyiNOgT1dOqDiVAQFwBH7gBRZr17gLrlFCRzF6jFh7Kew==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.19.12.tgz", + "integrity": "sha512-B6IeSgZgtEzGC42jsI+YYu9Z3HKRxp8ZT3cqhvliEHovq8HSX2YX8lNocDn79gCKJXOSaEot9MVYky7AKjCs8g==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.19.12.tgz", + "integrity": "sha512-hKoVkKzFiToTgn+41qGhsUJXFlIjxI/jSYeZf3ugemDYZldIXIxhvwN6erJGlX4t5h417iFuheZ7l+YVn05N3A==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.19.12.tgz", + "integrity": "sha512-4aRvFIXmwAcDBw9AueDQ2YnGmz5L6obe5kmPT8Vd+/+x/JMVKCgdcRwH6APrbpNXsPz+K653Qg8HB/oXvXVukA==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.19.12.tgz", + "integrity": "sha512-EYoXZ4d8xtBoVN7CEwWY2IN4ho76xjYXqSXMNccFSx2lgqOG/1TBPW0yPx1bJZk94qu3tX0fycJeeQsKovA8gg==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.19.12.tgz", + "integrity": "sha512-J5jPms//KhSNv+LO1S1TX1UWp1ucM6N6XuL6ITdKWElCu8wXP72l9MM0zDTzzeikVyqFE6U8YAV9/tFyj0ti+w==", + "cpu": [ + "arm" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.19.12.tgz", + "integrity": "sha512-EoTjyYyLuVPfdPLsGVVVC8a0p1BFFvtpQDB/YLEhaXyf/5bczaGeN15QkR+O4S5LeJ92Tqotve7i1jn35qwvdA==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.19.12.tgz", + "integrity": "sha512-Thsa42rrP1+UIGaWz47uydHSBOgTUnwBwNq59khgIwktK6x60Hivfbux9iNR0eHCHzOLjLMLfUMLCypBkZXMHA==", + "cpu": [ + "ia32" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.19.12.tgz", + "integrity": "sha512-LiXdXA0s3IqRRjm6rV6XaWATScKAXjI4R4LoDlvO7+yQqFdlr1Bax62sRwkVvRIrwXxvtYEHHI4dm50jAXkuAA==", + "cpu": [ + "loong64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.19.12.tgz", + "integrity": "sha512-fEnAuj5VGTanfJ07ff0gOA6IPsvrVHLVb6Lyd1g2/ed67oU1eFzL0r9WL7ZzscD+/N6i3dWumGE1Un4f7Amf+w==", + "cpu": [ + "mips64el" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.19.12.tgz", + "integrity": "sha512-nYJA2/QPimDQOh1rKWedNOe3Gfc8PabU7HT3iXWtNUbRzXS9+vgB0Fjaqr//XNbd82mCxHzik2qotuI89cfixg==", + "cpu": [ + "ppc64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.19.12.tgz", + "integrity": "sha512-2MueBrlPQCw5dVJJpQdUYgeqIzDQgw3QtiAHUC4RBz9FXPrskyyU3VI1hw7C0BSKB9OduwSJ79FTCqtGMWqJHg==", + "cpu": [ + "riscv64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.19.12.tgz", + "integrity": "sha512-+Pil1Nv3Umes4m3AZKqA2anfhJiVmNCYkPchwFJNEJN5QxmTs1uzyy4TvmDrCRNT2ApwSari7ZIgrPeUx4UZDg==", + "cpu": [ + "s390x" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.19.12.tgz", + "integrity": "sha512-B71g1QpxfwBvNrfyJdVDexenDIt1CiDN1TIXLbhOw0KhJzE78KIFGX6OJ9MrtC0oOqMWf+0xop4qEU8JrJTwCg==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.19.12.tgz", + "integrity": "sha512-3ltjQ7n1owJgFbuC61Oj++XhtzmymoCihNFgT84UAmJnxJfm4sYCiSLTXZtE00VWYpPMYc+ZQmB6xbSdVh0JWA==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.19.12.tgz", + "integrity": "sha512-RbrfTB9SWsr0kWmb9srfF+L933uMDdu9BIzdA7os2t0TXhCRjrQyCeOt6wVxr79CKD4c+p+YhCj31HBkYcXebw==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.19.12.tgz", + "integrity": "sha512-HKjJwRrW8uWtCQnQOz9qcU3mUZhTUQvi56Q8DPTLLB+DawoiQdjsYq+j+D3s9I8VFtDr+F9CjgXKKC4ss89IeA==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.19.12.tgz", + "integrity": "sha512-URgtR1dJnmGvX864pn1B2YUYNzjmXkuJOIqG2HdU62MVS4EHpU2946OZoTMnRUHklGtJdJZ33QfzdjGACXhn1A==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.19.12.tgz", + "integrity": "sha512-+ZOE6pUkMOJfmxmBZElNOx72NKpIa/HFOMGzu8fqzQJ5kgf6aTGrcJaFsNiVMH4JKpMipyK+7k0n2UXN7a8YKQ==", + "cpu": [ + "ia32" + ], + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.19.12.tgz", + "integrity": "sha512-T1QyPSDCyMXaO3pzBkF96E8xMkiRYbUEZADd29SyPGabqxMViNoii+NcK7eWJAEoU6RZyEm5lVSIjTmcdoB9HA==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@rollup/rollup-android-arm-eabi": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.9.6.tgz", + "integrity": "sha512-MVNXSSYN6QXOulbHpLMKYi60ppyO13W9my1qogeiAqtjb2yR4LSmfU2+POvDkLzhjYLXz9Rf9+9a3zFHW1Lecg==", + "cpu": [ + "arm" + ], + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-android-arm64": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.9.6.tgz", + "integrity": "sha512-T14aNLpqJ5wzKNf5jEDpv5zgyIqcpn1MlwCrUXLrwoADr2RkWA0vOWP4XxbO9aiO3dvMCQICZdKeDrFl7UMClw==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-darwin-arm64": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.9.6.tgz", + "integrity": "sha512-CqNNAyhRkTbo8VVZ5R85X73H3R5NX9ONnKbXuHisGWC0qRbTTxnF1U4V9NafzJbgGM0sHZpdO83pLPzq8uOZFw==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-darwin-x64": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.9.6.tgz", + "integrity": "sha512-zRDtdJuRvA1dc9Mp6BWYqAsU5oeLixdfUvkTHuiYOHwqYuQ4YgSmi6+/lPvSsqc/I0Omw3DdICx4Tfacdzmhog==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-linux-arm-gnueabihf": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.9.6.tgz", + "integrity": "sha512-oNk8YXDDnNyG4qlNb6is1ojTOGL/tRhbbKeE/YuccItzerEZT68Z9gHrY3ROh7axDc974+zYAPxK5SH0j/G+QQ==", + "cpu": [ + "arm" + ], + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-gnu": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.9.6.tgz", + "integrity": "sha512-Z3O60yxPtuCYobrtzjo0wlmvDdx2qZfeAWTyfOjEDqd08kthDKexLpV97KfAeUXPosENKd8uyJMRDfFMxcYkDQ==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-musl": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.9.6.tgz", + "integrity": "sha512-gpiG0qQJNdYEVad+1iAsGAbgAnZ8j07FapmnIAQgODKcOTjLEWM9sRb+MbQyVsYCnA0Im6M6QIq6ax7liws6eQ==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-riscv64-gnu": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.9.6.tgz", + "integrity": "sha512-+uCOcvVmFUYvVDr27aiyun9WgZk0tXe7ThuzoUTAukZJOwS5MrGbmSlNOhx1j80GdpqbOty05XqSl5w4dQvcOA==", + "cpu": [ + "riscv64" + ], + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-gnu": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.9.6.tgz", + "integrity": "sha512-HUNqM32dGzfBKuaDUBqFB7tP6VMN74eLZ33Q9Y1TBqRDn+qDonkAUyKWwF9BR9unV7QUzffLnz9GrnKvMqC/fw==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-musl": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.9.6.tgz", + "integrity": "sha512-ch7M+9Tr5R4FK40FHQk8VnML0Szi2KRujUgHXd/HjuH9ifH72GUmw6lStZBo3c3GB82vHa0ZoUfjfcM7JiiMrQ==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-win32-arm64-msvc": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.9.6.tgz", + "integrity": "sha512-VD6qnR99dhmTQ1mJhIzXsRcTBvTjbfbGGwKAHcu+52cVl15AC/kplkhxzW/uT0Xl62Y/meBKDZvoJSJN+vTeGA==", + "cpu": [ + "arm64" + ], + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-ia32-msvc": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.9.6.tgz", + "integrity": "sha512-J9AFDq/xiRI58eR2NIDfyVmTYGyIZmRcvcAoJ48oDld/NTR8wyiPUu2X/v1navJ+N/FGg68LEbX3Ejd6l8B7MQ==", + "cpu": [ + "ia32" + ], + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-x64-msvc": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.9.6.tgz", + "integrity": "sha512-jqzNLhNDvIZOrt69Ce4UjGRpXJBzhUBzawMwnaDAwyHriki3XollsewxWzOzz+4yOFDkuJHtTsZFwMxhYJWmLQ==", + "cpu": [ + "x64" + ], + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@types/estree": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", + "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==" + }, + "node_modules/accepts": { + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.8.tgz", + "integrity": "sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==", + "dependencies": { + "mime-types": "~2.1.34", + "negotiator": "0.6.3" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/array-flatten": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", + "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==" + }, + "node_modules/body-parser": { + "version": "1.20.1", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", + "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", + "dependencies": { + "bytes": "3.1.2", + "content-type": "~1.0.4", + "debug": "2.6.9", + "depd": "2.0.0", + "destroy": "1.2.0", + "http-errors": "2.0.0", + "iconv-lite": "0.4.24", + "on-finished": "2.4.1", + "qs": "6.11.0", + "raw-body": "2.5.1", + "type-is": "~1.6.18", + "unpipe": "1.0.0" + }, + "engines": { + "node": ">= 0.8", + "npm": "1.2.8000 || >= 1.4.16" + } + }, + "node_modules/bytes": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", + "integrity": "sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/call-bind": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.6.tgz", + "integrity": "sha512-Mj50FLHtlsoVfRfnHaZvyrooHcrlceNZdL/QBvJJVd9Ta55qCQK0gs4ss2oZDeV9zFCs6ewzYgVE5yfVmfFpVg==", + "dependencies": { + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.3", + "set-function-length": "^1.2.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/content-disposition": { + "version": "0.5.4", + "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.4.tgz", + "integrity": "sha512-FveZTNuGw04cxlAiWbzi6zTAL/lhehaWbTtgluJh4/E95DqMwTmha3KZN1aAWA8cFIhHzMZUvLevkw5Rqk+tSQ==", + "dependencies": { + "safe-buffer": "5.2.1" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/content-type": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.5.tgz", + "integrity": "sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/cookie": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", + "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/cookie-signature": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz", + "integrity": "sha512-QADzlaHc8icV8I7vbaJXJwod9HWYp8uCqf1xa4OfNu1T7JVxQIrUgOWtHdNDtPiywmFbiS12VjotIXLrKM3orQ==" + }, + "node_modules/debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dependencies": { + "ms": "2.0.0" + } + }, + "node_modules/define-data-property": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.2.tgz", + "integrity": "sha512-SRtsSqsDbgpJBbW3pABMCOt6rQyeM8s8RiyeSN8jYG8sYmt/kGJejbydttUsnDs1tadr19tvhT4ShwMyoqAm4g==", + "dependencies": { + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.2", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/depd": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", + "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/destroy": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.2.0.tgz", + "integrity": "sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg==", + "engines": { + "node": ">= 0.8", + "npm": "1.2.8000 || >= 1.4.16" + } + }, + "node_modules/ee-first": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", + "integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==" + }, + "node_modules/encodeurl": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", + "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/es-errors": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", + "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/esbuild": { + "version": "0.19.12", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.19.12.tgz", + "integrity": "sha512-aARqgq8roFBj054KvQr5f1sFu0D65G+miZRCuJyJ0G13Zwx7vRar5Zhn2tkQNzIXcBrNVsv/8stehpj+GAjgbg==", + "hasInstallScript": true, + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=12" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.19.12", + "@esbuild/android-arm": "0.19.12", + "@esbuild/android-arm64": "0.19.12", + "@esbuild/android-x64": "0.19.12", + "@esbuild/darwin-arm64": "0.19.12", + "@esbuild/darwin-x64": "0.19.12", + "@esbuild/freebsd-arm64": "0.19.12", + "@esbuild/freebsd-x64": "0.19.12", + "@esbuild/linux-arm": "0.19.12", + "@esbuild/linux-arm64": "0.19.12", + "@esbuild/linux-ia32": "0.19.12", + "@esbuild/linux-loong64": "0.19.12", + "@esbuild/linux-mips64el": "0.19.12", + "@esbuild/linux-ppc64": "0.19.12", + "@esbuild/linux-riscv64": "0.19.12", + "@esbuild/linux-s390x": "0.19.12", + "@esbuild/linux-x64": "0.19.12", + "@esbuild/netbsd-x64": "0.19.12", + "@esbuild/openbsd-x64": "0.19.12", + "@esbuild/sunos-x64": "0.19.12", + "@esbuild/win32-arm64": "0.19.12", + "@esbuild/win32-ia32": "0.19.12", + "@esbuild/win32-x64": "0.19.12" + } + }, + "node_modules/escape-html": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", + "integrity": "sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==" + }, + "node_modules/etag": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", + "integrity": "sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/express": { + "version": "4.18.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", + "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "dependencies": { + "accepts": "~1.3.8", + "array-flatten": "1.1.1", + "body-parser": "1.20.1", + "content-disposition": "0.5.4", + "content-type": "~1.0.4", + "cookie": "0.5.0", + "cookie-signature": "1.0.6", + "debug": "2.6.9", + "depd": "2.0.0", + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "etag": "~1.8.1", + "finalhandler": "1.2.0", + "fresh": "0.5.2", + "http-errors": "2.0.0", + "merge-descriptors": "1.0.1", + "methods": "~1.1.2", + "on-finished": "2.4.1", + "parseurl": "~1.3.3", + "path-to-regexp": "0.1.7", + "proxy-addr": "~2.0.7", + "qs": "6.11.0", + "range-parser": "~1.2.1", + "safe-buffer": "5.2.1", + "send": "0.18.0", + "serve-static": "1.15.0", + "setprototypeof": "1.2.0", + "statuses": "2.0.1", + "type-is": "~1.6.18", + "utils-merge": "1.0.1", + "vary": "~1.1.2" + }, + "engines": { + "node": ">= 0.10.0" + } + }, + "node_modules/finalhandler": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.2.0.tgz", + "integrity": "sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg==", + "dependencies": { + "debug": "2.6.9", + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "on-finished": "2.4.1", + "parseurl": "~1.3.3", + "statuses": "2.0.1", + "unpipe": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/forwarded": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz", + "integrity": "sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/fresh": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", + "integrity": "sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/function-bind": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", + "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-intrinsic": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz", + "integrity": "sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==", + "dependencies": { + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "hasown": "^2.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "dependencies": { + "get-intrinsic": "^1.1.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/handlebars": { + "version": "4.7.8", + "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.7.8.tgz", + "integrity": "sha512-vafaFqs8MZkRrSX7sFVUdo3ap/eNiLnb4IakshzvP56X5Nr1iGKAIqdX6tMlm6HcNRIkr6AxO5jFEoJzzpT8aQ==", + "dependencies": { + "minimist": "^1.2.5", + "neo-async": "^2.6.2", + "source-map": "^0.6.1", + "wordwrap": "^1.0.0" + }, + "bin": { + "handlebars": "bin/handlebars" + }, + "engines": { + "node": ">=0.4.7" + }, + "optionalDependencies": { + "uglify-js": "^3.1.4" + } + }, + "node_modules/has-property-descriptors": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.1.tgz", + "integrity": "sha512-VsX8eaIewvas0xnvinAe9bw4WfIeODpGYikiWYLH+dma0Jw6KHYqWiWfhQlgOVK8D6PvjubK5Uc4P0iIhIcNVg==", + "dependencies": { + "get-intrinsic": "^1.2.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", + "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/hasown": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.0.tgz", + "integrity": "sha512-vUptKVTpIJhcczKBbgnS+RtcuYMB8+oNzPK2/Hp3hanz8JmpATdmmgLgSaadVREkDm+e2giHwY3ZRkyjSIDDFA==", + "dependencies": { + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/http-errors": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.0.tgz", + "integrity": "sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ==", + "dependencies": { + "depd": "2.0.0", + "inherits": "2.0.4", + "setprototypeof": "1.2.0", + "statuses": "2.0.1", + "toidentifier": "1.0.1" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/iconv-lite": { + "version": "0.4.24", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", + "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "node_modules/ipaddr.js": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz", + "integrity": "sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==", + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/lodash-es": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash-es/-/lodash-es-4.17.21.tgz", + "integrity": "sha512-mKnC+QJ9pWVzv+C4/U3rRsHapFfHvQFoFB92e52xeyGMcX6/OlIl78je1u8vePzYZSkkogMPJ2yjxxsb89cxyw==" + }, + "node_modules/media-typer": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", + "integrity": "sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/merge-descriptors": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", + "integrity": "sha512-cCi6g3/Zr1iqQi6ySbseM1Xvooa98N0w31jzUYrXPX2xqObmFGHJ0tQ5u74H3mVh7wLouTseZyYIq39g8cNp1w==" + }, + "node_modules/methods": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", + "integrity": "sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", + "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==", + "bin": { + "mime": "cli.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "dependencies": { + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==" + }, + "node_modules/nanoid": { + "version": "3.3.7", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.7.tgz", + "integrity": "sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, + "node_modules/negotiator": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.3.tgz", + "integrity": "sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/neo-async": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz", + "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==" + }, + "node_modules/object-inspect": { + "version": "1.13.1", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.1.tgz", + "integrity": "sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/on-finished": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.4.1.tgz", + "integrity": "sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg==", + "dependencies": { + "ee-first": "1.1.1" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/parseurl": { + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", + "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/path-to-regexp": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", + "integrity": "sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ==" + }, + "node_modules/picocolors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", + "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==" + }, + "node_modules/postcss": { + "version": "8.4.33", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.33.tgz", + "integrity": "sha512-Kkpbhhdjw2qQs2O2DGX+8m5OVqEcbB9HRBvuYM9pgrjEFUg30A9LmXNlTAUj4S9kgtGyrMbTzVjH7E+s5Re2yg==", + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "nanoid": "^3.3.7", + "picocolors": "^1.0.0", + "source-map-js": "^1.0.2" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/proxy-addr": { + "version": "2.0.7", + "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.7.tgz", + "integrity": "sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg==", + "dependencies": { + "forwarded": "0.2.0", + "ipaddr.js": "1.9.1" + }, + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/qs": { + "version": "6.11.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.0.tgz", + "integrity": "sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==", + "dependencies": { + "side-channel": "^1.0.4" + }, + "engines": { + "node": ">=0.6" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/range-parser": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", + "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/raw-body": { + "version": "2.5.1", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", + "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", + "dependencies": { + "bytes": "3.1.2", + "http-errors": "2.0.0", + "iconv-lite": "0.4.24", + "unpipe": "1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/rollup": { + "version": "4.9.6", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.9.6.tgz", + "integrity": "sha512-05lzkCS2uASX0CiLFybYfVkwNbKZG5NFQ6Go0VWyogFTXXbR039UVsegViTntkk4OglHBdF54ccApXRRuXRbsg==", + "dependencies": { + "@types/estree": "1.0.5" + }, + "bin": { + "rollup": "dist/bin/rollup" + }, + "engines": { + "node": ">=18.0.0", + "npm": ">=8.0.0" + }, + "optionalDependencies": { + "@rollup/rollup-android-arm-eabi": "4.9.6", + "@rollup/rollup-android-arm64": "4.9.6", + "@rollup/rollup-darwin-arm64": "4.9.6", + "@rollup/rollup-darwin-x64": "4.9.6", + "@rollup/rollup-linux-arm-gnueabihf": "4.9.6", + "@rollup/rollup-linux-arm64-gnu": "4.9.6", + "@rollup/rollup-linux-arm64-musl": "4.9.6", + "@rollup/rollup-linux-riscv64-gnu": "4.9.6", + "@rollup/rollup-linux-x64-gnu": "4.9.6", + "@rollup/rollup-linux-x64-musl": "4.9.6", + "@rollup/rollup-win32-arm64-msvc": "4.9.6", + "@rollup/rollup-win32-ia32-msvc": "4.9.6", + "@rollup/rollup-win32-x64-msvc": "4.9.6", + "fsevents": "~2.3.2" + } + }, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" + }, + "node_modules/send": { + "version": "0.18.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", + "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "dependencies": { + "debug": "2.6.9", + "depd": "2.0.0", + "destroy": "1.2.0", + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "etag": "~1.8.1", + "fresh": "0.5.2", + "http-errors": "2.0.0", + "mime": "1.6.0", + "ms": "2.1.3", + "on-finished": "2.4.1", + "range-parser": "~1.2.1", + "statuses": "2.0.1" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/send/node_modules/ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==" + }, + "node_modules/serve-static": { + "version": "1.15.0", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.15.0.tgz", + "integrity": "sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==", + "dependencies": { + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "parseurl": "~1.3.3", + "send": "0.18.0" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/set-function-length": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.1.tgz", + "integrity": "sha512-j4t6ccc+VsKwYHso+kElc5neZpjtq9EnRICFZtWyBsLojhmeF/ZBd/elqm22WJh/BziDe/SBiOeAt0m2mfLD0g==", + "dependencies": { + "define-data-property": "^1.1.2", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.3", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/setprototypeof": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", + "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==" + }, + "node_modules/side-channel": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.5.tgz", + "integrity": "sha512-QcgiIWV4WV7qWExbN5llt6frQB/lBven9pqliLXfGPB+K9ZYXxDozp0wLkHS24kWCm+6YXH/f0HhnObZnZOBnQ==", + "dependencies": { + "call-bind": "^1.0.6", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.4", + "object-inspect": "^1.13.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/source-map-js": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.0.2.tgz", + "integrity": "sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/statuses": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", + "integrity": "sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/toidentifier": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.1.tgz", + "integrity": "sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==", + "engines": { + "node": ">=0.6" + } + }, + "node_modules/type-is": { + "version": "1.6.18", + "resolved": "https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz", + "integrity": "sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==", + "dependencies": { + "media-typer": "0.3.0", + "mime-types": "~2.1.24" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/uglify-js": { + "version": "3.17.4", + "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.17.4.tgz", + "integrity": "sha512-T9q82TJI9e/C1TAxYvfb16xO120tMVFZrGA3f9/P4424DNu6ypK103y0GPFVa17yotwSyZW5iYXgjYHkGrJW/g==", + "optional": true, + "bin": { + "uglifyjs": "bin/uglifyjs" + }, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/unpipe": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", + "integrity": "sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/utils-merge": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz", + "integrity": "sha512-pMZTvIkT1d+TFGvDOqodOclx0QWkkgi6Tdoa8gC8ffGAAqz9pzPTZWAybbsHHoED/ztMtkv/VoYTYyShUn81hA==", + "engines": { + "node": ">= 0.4.0" + } + }, + "node_modules/vary": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", + "integrity": "sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/vite": { + "version": "5.0.12", + "resolved": "https://registry.npmjs.org/vite/-/vite-5.0.12.tgz", + "integrity": "sha512-4hsnEkG3q0N4Tzf1+t6NdN9dg/L3BM+q8SWgbSPnJvrgH2kgdyzfVJwbR1ic69/4uMJJ/3dqDZZE5/WwqW8U1w==", + "dependencies": { + "esbuild": "^0.19.3", + "postcss": "^8.4.32", + "rollup": "^4.2.0" + }, + "bin": { + "vite": "bin/vite.js" + }, + "engines": { + "node": "^18.0.0 || >=20.0.0" + }, + "funding": { + "url": "https://github.com/vitejs/vite?sponsor=1" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + }, + "peerDependencies": { + "@types/node": "^18.0.0 || >=20.0.0", + "less": "*", + "lightningcss": "^1.21.0", + "sass": "*", + "stylus": "*", + "sugarss": "*", + "terser": "^5.4.0" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "less": { + "optional": true + }, + "lightningcss": { + "optional": true + }, + "sass": { + "optional": true + }, + "stylus": { + "optional": true + }, + "sugarss": { + "optional": true + }, + "terser": { + "optional": true + } + } + }, + "node_modules/vite-plugin-handlebars": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/vite-plugin-handlebars/-/vite-plugin-handlebars-2.0.0.tgz", + "integrity": "sha512-+J3It0nyhPzx4nT1I+fnWH+jShTEXzm6X0Tgsggdm9IYFD7/eJ6a3ROI13HTe0CVoyaxm/fPxH5HDAKyfz7T0g==", + "dependencies": { + "handlebars": "^4.7.6", + "vite": "^5.0.0" + } + }, + "node_modules/wordwrap": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz", + "integrity": "sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q==" + } + } +} diff --git a/package.json b/package.json new file mode 100644 index 000000000..1a2ca4959 --- /dev/null +++ b/package.json @@ -0,0 +1,25 @@ +{ + "name": "sprint_1", + "private": true, + "version": "0.0.0", + "type": "module", + "engines": { + "node": ">=12" + }, + "scripts": { + "dev": "vite", + "build": "vite build", + "server": "node server.js", + "start": "npm run build && npm run server", + "preview": "vite preview" + }, + "devDependencies": { + "handlebars": "^4.7.8", + "vite": "^5.0.8" + }, + "dependencies": { + "express": "^4.18.2", + "lodash-es": "^4.17.21", + "vite-plugin-handlebars": "^2.0.0" + } +} diff --git a/server.js b/server.js new file mode 100644 index 000000000..960c0eb0b --- /dev/null +++ b/server.js @@ -0,0 +1,19 @@ +import express from 'express'; +import path from 'path'; +import { fileURLToPath } from 'url'; + +const __filename = fileURLToPath(import.meta.url); +const __dirname = path.dirname(__filename); + +const app = express(); +const PORT = 3000; + +app.use(express.static(__dirname + '/dist')); + +app.get('*', (req, res) => { + res.sendFile(path.join(__dirname, '/dist/index.html')); +}); + +app.listen(PORT, function () { + console.log(`Example app listening on port ${PORT}!`); +}); \ No newline at end of file diff --git a/src/components/Button/buttons.js b/src/components/Button/buttons.js new file mode 100644 index 000000000..49bb4167b --- /dev/null +++ b/src/components/Button/buttons.js @@ -0,0 +1,11 @@ +import Handlebars from 'handlebars'; + +export const button = ({text, url}) => Handlebars.compile(` +`)({text, url}) + +export const button_blue = ({text, url}) => Handlebars.compile(` +`)({text, url}) + +export const button_blue_static = ({text, url}) => Handlebars.compile(` +`)({text, url}) + diff --git a/src/components/Input/input.js b/src/components/Input/input.js new file mode 100644 index 000000000..ff11b0498 --- /dev/null +++ b/src/components/Input/input.js @@ -0,0 +1,17 @@ +import Handlebars from 'handlebars'; + +export const input = ({text, type, name, placeholder}) => Handlebars.compile(` +
+
+

{{text}}

+
+ +
+`)({text, type, name, placeholder}); + +export const simply_input = ({text, type, name, placeholder}) => Handlebars.compile(` + +`)({text, type, name, placeholder}) + + + diff --git a/src/components/Svg/svg.js b/src/components/Svg/svg.js new file mode 100644 index 000000000..e24196540 --- /dev/null +++ b/src/components/Svg/svg.js @@ -0,0 +1,16 @@ +import Handlebars from "handlebars"; + +export const svg_arrow_right = (width, height) => Handlebars.compile(` + + + +`)({width, height}); + + +export const svg_send = (width, height) => Handlebars.compile(` + + + + + +`)({width, height}); diff --git a/src/index.html b/src/index.html new file mode 100644 index 000000000..d348a8b62 --- /dev/null +++ b/src/index.html @@ -0,0 +1,17 @@ + + + + + + chat2you + + + + +
+
+
+ + + + diff --git a/src/main.js b/src/main.js new file mode 100644 index 000000000..0757d20fd --- /dev/null +++ b/src/main.js @@ -0,0 +1,33 @@ +import {showAuth} from "./pages/auth/auth.js"; +import {showRegister} from "./pages/register/register.js"; +import {showMessages} from "./pages/messages/messages.js"; +import {showProfile} from "./pages/profile/profile.js"; +import {showError} from "./pages/errors/index.js"; + +document.addEventListener("DOMContentLoaded", () => { + const root = document.getElementById("app"); + root.innerHTML = ""; + const loc = window.location.pathname; + const loadPage = (path) => { + if (path === "/" || path === "") { + window.location.href = "/login"; + } else if (path === "/login") { + return showAuth(); + } else if (path === "/register") { + return showRegister(); + } else if (path === "/messages") { + return showMessages(); + } else if (path === "/profile") { + return showProfile(); + } else if (path === "/profile-edit") { + return showProfile("edit"); + } else if (path === "/profile-edit-password") { + return showProfile("password"); + } else if (path === "/500") { + return showError(500); + } else { + return showError(); + } + }; + root.innerHTML = loadPage(loc); +}); \ No newline at end of file diff --git a/src/pages/auth/auth.js b/src/pages/auth/auth.js new file mode 100644 index 000000000..2375a3d14 --- /dev/null +++ b/src/pages/auth/auth.js @@ -0,0 +1,26 @@ +import Handlebars from "handlebars"; +import { template } from "./auth.tmpl.js"; +import { button } from "../../components/Button/buttons.js"; +import { input } from "../../components/Input/input.js"; + +const title = "Вход"; +const authButton = button({ + url: "/messages", + text: "Авторизация", +}); +const inp = input({ + text: "Логин", + type: "text", + name: "login", + placeholder: "ivanivavov", +}) + +const inp2 = input({ + text: "Пароль", + type: "password", + name: "password", + placeholder: "***********", +}) + +export const showAuth = () => + Handlebars.compile(template)({ button: authButton, title, inp, inp2 }); diff --git a/src/pages/auth/auth.tmpl.js b/src/pages/auth/auth.tmpl.js new file mode 100644 index 000000000..ed8048cc4 --- /dev/null +++ b/src/pages/auth/auth.tmpl.js @@ -0,0 +1,17 @@ +export const template = ` +
+
+

{{title}}

+
+
+ {{{inp}}} + {{{inp2}}} +
+ + {{{button}}} + Нет аккаунта? +
+ +
+
+` diff --git a/src/pages/errors/error.tmpl.js b/src/pages/errors/error.tmpl.js new file mode 100644 index 000000000..964d5d125 --- /dev/null +++ b/src/pages/errors/error.tmpl.js @@ -0,0 +1,7 @@ +export const template = ` +
+

{{code}}

+

{{text}}

+ Назад +
+` diff --git a/src/pages/errors/index.js b/src/pages/errors/index.js new file mode 100644 index 000000000..4257a358a --- /dev/null +++ b/src/pages/errors/index.js @@ -0,0 +1,22 @@ +import Handlebars from "handlebars"; +import { template } from "./error.tmpl.js"; + +const code_500 = "500"; +const text_500 = "Мы уже работаем на решением данной проблемы"; + +const code_404 = "404"; +const text_404 = "OOPS, вы не туда попали"; + +export const error_500 = () => + Handlebars.compile(template)({ code: code_500, text: text_500 }); + +export const error_404 = () => + Handlebars.compile(template)({ code: code_404, text: text_404 }); + +export const showError = (code = 404) => { + if(code === 500) { + return error_500(); + } else { + return error_404(); + } +}; diff --git a/src/pages/errors/style.less b/src/pages/errors/style.less new file mode 100644 index 000000000..261551b31 --- /dev/null +++ b/src/pages/errors/style.less @@ -0,0 +1,38 @@ +@viewport-width: 1280px; +@percent: (100vw / @viewport-width) * 12px; +@percent2: (100vw / @viewport-width) / 114px; + +.error_page { + width: 100vw; + height: 100vh; + display: flex; + flex-direction: column; + align-items: center; + position: relative; + justify-content: flex-start; + + h1 { + font-size: 120px; + color: #1E1E1E; + margin-top: 150px; + margin-bottom: 50px; + } + + p { + font-size: 20px; + color: #1E1E1E; + } + + a { + color: #3369F3; + font-size: 24px; + position: absolute; + bottom: 50%; + transform: translateY(-50%); + text-decoration: none; + &:hover { + color: #2a56c5; + } + } + +} \ No newline at end of file diff --git a/src/pages/messages/messages.css b/src/pages/messages/messages.css new file mode 100644 index 000000000..67c2e7c52 --- /dev/null +++ b/src/pages/messages/messages.css @@ -0,0 +1,238 @@ +*:focus { + outline: none; +} +body { + margin: 0; + font-family: 'Inter', sans-serif; +} +.messages { + display: flex; + height: 100vh; +} +.chats { + width: 24%; + border-right: 1px solid #EAEAEA; + min-width: 24%; + max-width: 24%; + overflow: hidden; +} +.chats .profile { + display: inline-block; + padding-right: 7.4%; + margin-top: 21px; + margin-bottom: 23px; + color: #999999; + font-size: 0.9375vw; + line-height: 0.9375vw; + text-align: right; + width: 100%; + box-sizing: border-box; + text-decoration: none; +} +.chats .profile:hover { + color: #726969; + text-decoration: underline; +} +.chats .search { + margin-left: 10px; + margin-right: 11px; + border-bottom: 1px solid #EAEAEA; + padding-bottom: 7px; +} +.chats .search input { + position: relative; + width: 100%; + background-color: #EFEFEF; + border-radius: 5px; + border: none; + height: 32px; + text-align: center; + font-size: 0.9375vw; + line-height: 0.9375vw; +} +.chat_list { + width: 100%; + display: flex; + flex-direction: column; +} +.chat { + display: flex; + justify-content: space-between; + margin-left: 10px; + padding-right: 10px; + padding-bottom: 12px; + border-bottom: 1px solid #EAEAEA; + padding-top: 12px; +} +.chat_active { + background-color: #E4EDFD; +} +.chat:hover { + background-color: #EFEFEF; + cursor: pointer; +} +.chat .image { + background-color: #EFEFEF; + width: 47px; + height: 47px; + border-radius: 50%; + margin-right: 10px; +} +.chat .data { + width: 77%; +} +.chat .name { + color: #1E1E1E; + font-size: 13px; + line-height: 13px; + font-weight: 600; + margin-bottom: 4px; +} +.chat .text { + color: #999999; + text-overflow: ellipsis; + overflow: hidden; + -webkit-line-clamp: 2; + display: -webkit-box; + -webkit-box-orient: vertical; + font-size: 13px; + line-height: 15px; + width: 99%; +} +.chat .text b { + color: #1E1E1E; + font-size: 12px; + font-weight: 600; +} +.chat .info { + display: flex; + flex-direction: column; + align-items: center; + justify-content: space-between; +} +.chat .info .date { + color: #999999; + font-size: 9px; +} +.chat .info .new { + width: 20px; + height: 20px; + background-color: #3369F3; + font-weight: 600; + color: #fff; + border-radius: 50%; + position: relative; +} +.chat .info .new p { + position: absolute; + font-size: 11px; + top: 50%; + left: 50%; + transform: translate(-50%, -50%); + padding: 0; + margin: 0; +} +.content { + width: 100%; + display: flex; + flex-direction: column; + justify-content: space-between; +} +.content .content_messages { + height: 100%; + display: flex; + flex-direction: column-reverse; +} +.content .chat_header { + position: relative; + margin-left: 20px; + margin-right: 20px; + height: 54px; + border-bottom: 1px solid #EAEAEA; + display: flex; + align-items: center; + justify-content: center; +} +.content .chat_header .more { + position: absolute; + right: 11px; + top: 20px; + width: 10px; + padding-left: 10px; +} +.content .chat_header .more:hover { + cursor: pointer; +} +.content .chat_header .more:hover path { + color: red; + fill: #e80909; +} +.content .chat_header .chat_header_info { + display: flex; + flex-direction: row; + align-items: center; +} +.content .chat_header .chat_header_info .chat_header_name { + margin-left: 10px; + font-size: 13px; + font-weight: 600; +} +.content .chat_header .chat_header_info .image { + background-color: #EFEFEF; + width: 34px; + height: 34px; + border-radius: 50%; +} +.content .chat_bottom { + border-top: 1px solid #EAEAEA; + height: 54px; + margin-left: 20px; + margin-right: 20px; + display: flex; + flex-direction: row; + justify-content: space-between; + box-sizing: border-box; + min-height: 54px; + max-height: 54px; + align-items: center; +} +.content .chat_bottom .file, +.content .chat_bottom .send { + cursor: pointer; +} +.content .chat_bottom .file:hover, +.content .chat_bottom .send:hover { + fill: red; +} +.content .chat_bottom .send_area { + border-radius: 30px; + font-size: 12px; + color: #999999; + padding: 10px 20px; + background-color: #EFEFEF; + width: 100%; + margin-right: 10px; + margin-left: 10px; + border: none; +} +.content .content_messages_message { + display: flex; + flex-direction: column-reverse; + margin-bottom: 30px; + margin-left: 20px; + padding: 11px; + max-width: 50%; + min-width: 404px; + background-color: #F8F8F8; + border-top-right-radius: 10px; + border-bottom-right-radius: 10px; + position: relative; +} +.content .content_messages_message .time { + position: absolute; + bottom: 10px; + right: 10px; + color: #999999; + font-size: 9px; +} +/*# sourceMappingURL=messages.css.map */ \ No newline at end of file diff --git a/src/pages/messages/messages.css.map b/src/pages/messages/messages.css.map new file mode 100644 index 000000000..2d5858d68 --- /dev/null +++ b/src/pages/messages/messages.css.map @@ -0,0 +1 @@ +{"version":3,"sources":["messages.less"],"names":[],"mappings":"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","file":"messages.css"} \ No newline at end of file diff --git a/src/pages/messages/messages.html b/src/pages/messages/messages.html new file mode 100644 index 000000000..4ff83ad26 --- /dev/null +++ b/src/pages/messages/messages.html @@ -0,0 +1,114 @@ + + + + + + + + Document + + +
+
+ Профиль + + + + +
+
+
+
+
Andrey
+
Wow, i see new feature Wow, i see new featureWow, i see new featureWow, i see new featureWow, i see new feature
+
+
+
10:49
+
+

2

+
+
+
+
+
+
+
Andrey
+
Привет! Смотри, тут всплыл интересный кусок лунной космической истории — НАСА в какой-то момент попросила Хассельблад адаптировать модель SWC для полетов на Луну. + Сейчас мы все знаем что астронавты летали с моделью 500 EL — и к слову говоря, все тушки этих камер все еще находятся на поверхности Луны, так как астронавты с собой забрали только кассеты с пленкой. + Хассельблад в итоге адаптировал SWC для космоса, но что-то пошло не так и на ракету они так никогда и не попали. Всего их было произведено 25 штук, одну из них недавно продали на аукционе за 45000 евро.
+
+
+
10:49
+
+

2

+
+
+
+
+
+
+
Andrey
+
Вы: Wow, i see new feature Wow, i see new featureWow, i see new featureWow, i see new featureWow, i see new feature
+
+
+
10:49
+ +
+
+
+
+
+
+
+
+
Andrey
+
+
+ + + + + + +
+
+
+
+ Привет! Смотри, тут всплыл интересный кусок лунной космической истории — НАСА в какой-то момент попросила Хассельблад адаптировать модель SWC для полетов на Луну. Сейчас мы все знаем что астронавты летали с моделью 500 EL — и к слову говоря, все тушки этих камер все еще находятся на поверхности Луны, так как астронавты с собой забрали только кассеты с пленкой. + Хассельблад в итоге адаптировал SWC для космоса, но что-то пошло не так и на ракету они так никогда и не попали. Всего их было произведено 25 штук, одну из них недавно продали на аукционе за 45000 евро. +
+ 11:56 +
+
+
+
+
+ + + + + + + + + +
+ + + +
+ + + + + + +
+
+
+
+ + \ No newline at end of file diff --git a/src/pages/messages/messages.js b/src/pages/messages/messages.js new file mode 100644 index 000000000..504fe59e8 --- /dev/null +++ b/src/pages/messages/messages.js @@ -0,0 +1,90 @@ +import Handlebars from "handlebars"; +import {template} from "./messages.tmpl.js"; +import {simply_input} from "../../components/Input/input.js"; +import {svg_arrow_right, svg_send} from "../../components/Svg/svg.js"; + +const input_search = simply_input({ + type: "text", + placeholder: "Поиск", + name: "search", +}); + + +export const svg_search = (width, height) => Handlebars.compile(` + + + +`)({width, height}); + +export const more_svg = (width, height) => Handlebars.compile(` + + + + + +`)({width, height}); + +export const svg_file = (width, height) => Handlebars.compile(` + + + + + + + + + +`)({width, height}); + +export const chat_list = []; +chat_list.push( + { + name: "Andray", + last_message: { + text: "Значимость этих проблем настолько очевидна, что дальнейшее развитие различных форм деятельности позволяет оценить значение системы массового участия. " + + "Идейные соображения высшего порядка, а также начало повседневной работы по формированию позиции позволяет выполнить важные задания по разработке вывода текущих активов.", + date: "10:42", // Пока ток время, понятно что тут прокидывается timestamp и проверяем today, this week + new_messages: 2, + me: true, + }, + }, + { + active: true, + name: "Admin", + last_message: { + text: "Привет, как твои дела, почему не отвечаешь????", + date: "12:21", // Пока ток время, понятно что тут прокидывается timestamp и проверяем today, this week + new_messages: 1, + }, + }, + { + name: "Научка", + last_message: { + text: "Внимание, в коментах заметили бредик, бредик не пишем! Пишем только хорошее!", + date: "12:21", // Пока ток время, понятно что тут прокидывается timestamp и проверяем today, this week + }, + } +) + +export const chat_messages = [ + { + text: "Привет, как твои дела, почему не отвечаешь????", + date: "20:11", + author: { + user_id: 31, + name: "Vevcor", + } + } +]; + +export const showMessages = () => + Handlebars.compile(template)({ + input_search, + chat_list, + chat_messages, + svg_file: svg_file(32, 32), + svg_search: svg_search(20, 20), + svg_arrow_right: svg_arrow_right(6, 10), + svg_send: svg_send(28, 28), + more_svg: more_svg(3, 16), + }); diff --git a/src/pages/messages/messages.less b/src/pages/messages/messages.less new file mode 100644 index 000000000..665f243ce --- /dev/null +++ b/src/pages/messages/messages.less @@ -0,0 +1,276 @@ +@viewport-width: 1280px; +@percent: (100vw / @viewport-width) * 12px; +@percent2: (100vw / @viewport-width) / 114px; + +*:focus { + outline: none; +} + + +body { + margin: 0; + font-family: 'Inter', sans-serif; +} + +.messages { + display: flex; + + height: 100vh; +} + +.chats { + //background-color: #535bf2; + width: 24%; + border-right: 1px solid #EAEAEA; + min-width: 24%; + max-width: 24%; + overflow: hidden; + + .profile { + display: inline-block; + padding-right: 7.4%; + margin-top: 21px; + margin-bottom: 23px; + color: #999999; + font-size: @percent; + line-height: @percent; + text-align: right; + width: 100%; + box-sizing: border-box; + text-decoration: none; + &:hover { + color: #726969; + text-decoration: underline; + } + } + + .search { + margin-left: 10px; + margin-right: 11px; + border-bottom: 1px solid #EAEAEA; + padding-bottom: 7px; + + input { + position: relative; + width: 100%; + background-color: #EFEFEF; + border-radius: 5px; + border: none; + height: 32px; + text-align: center; + font-size: @percent; + line-height: @percent; + } + } +} + +.chat_list { + width: 100%; + display: flex; + flex-direction: column; + +} + +.chat { + display: flex; + justify-content: space-between; + margin-left: 10px; + padding-right: 10px; + padding-bottom: 12px; + border-bottom: 1px solid #EAEAEA; + padding-top: 12px; + + &_active { + background-color: #E4EDFD; + } + + &:hover { + background-color: #EFEFEF; + cursor: pointer; + } + + .image { + background-color: #EFEFEF; + width: 47px; + height: 47px; + border-radius: 50%; + margin-right: 10px; + } + .data { + width: 77%; + } + + .name { + color: #1E1E1E; + font-size: 13px; + line-height: 13px; + font-weight: 600; + margin-bottom: 4px; + } + + .text { + color: #999999; + text-overflow: ellipsis; + overflow: hidden; + -webkit-line-clamp: 2; + display: -webkit-box; + -webkit-box-orient: vertical; + font-size: 13px; + line-height: 15px; + width: 99%; + + b{ + color: #1E1E1E; + font-size: 12px; + font-weight: 600; + } + } + + .info { + display: flex; + flex-direction: column; + align-items: center; + justify-content: space-between; + + .date { + color: #999999; + font-size: 9px; + } + + .new { + width: 20px; + height: 20px; + background-color: #3369F3; + font-weight: 600; + color: #fff; + border-radius: 50%; + position: relative; + + p { + position: absolute; + font-size: 11px; + top: 50%; + left: 50%; + transform: translate(-50%, -50%); + padding: 0; + margin: 0; + } + } + } + +} + + +.content { + width: 100%; + display: flex; + flex-direction: column; + justify-content: space-between; + + .content_messages { + height: 100%; + display: flex; + flex-direction: column-reverse; + } + + .chat_header { + position: relative; + margin-left: 20px; + margin-right: 20px; + height: 54px; + border-bottom: 1px solid #EAEAEA; + + display: flex; + align-items: center; + justify-content: center; + + .more { + position: absolute; + right: 11px; + top: 20px; + width: 10px; + padding-left: 10px; + &:hover { + cursor: pointer; + } + &:hover path { + color: red; + fill: #e80909; + } + } + + .chat_header_info { + display: flex; + flex-direction: row; + align-items: center; + + .chat_header_name { + margin-left: 10px; + font-size: 13px; + font-weight: 600; + } + + .image { + background-color: #EFEFEF; + width: 34px; + height: 34px; + border-radius: 50%; + } + } + } + + .chat_bottom { + border-top: 1px solid #EAEAEA; + height: 54px; + margin-left: 20px; + margin-right: 20px; + display: flex; + flex-direction: row; + justify-content: space-between; + box-sizing: border-box; + min-height: 54px; + max-height: 54px; + align-items: center; + + .file, .send { + cursor: pointer; + &:hover { + fill: red; + } + } + + .send_area { + border-radius: 30px; + font-size: 12px; + color: #999999; + padding: 10px 20px; + background-color: #EFEFEF; + width: 100%; + margin-right: 10px; + margin-left: 10px; + border: none; + } + } + + .content_messages_message { + display: flex; + flex-direction: column-reverse; + margin-bottom: 30px; + margin-left: 20px; + padding: 11px; + max-width: 50%; + min-width: 404px; + background-color: #F8F8F8; + border-top-right-radius: 10px; + border-bottom-right-radius: 10px; + position: relative; + + .time { + position: absolute; + bottom: 10px; + right: 10px; + color: #999999; + font-size: 9px; + } + } +} \ No newline at end of file diff --git a/src/pages/messages/messages.tmpl.js b/src/pages/messages/messages.tmpl.js new file mode 100644 index 000000000..4e473aea2 --- /dev/null +++ b/src/pages/messages/messages.tmpl.js @@ -0,0 +1,73 @@ +export const template = ` +
+
+ Профиль {{{svg_arrow_right}}} + +
+ {{#each chat_list}} + + {{#if this.active}} +
+ {{else}} +
+ {{/if}} + +
+
+
{{{this.name}}}
+
{{this.last_message.text}}
+
+
+
{{this.last_message.date}}
+ {{#if this.last_message.new_messages}} +
+

{{this.last_message.new_messages}}

+
+ {{/if}} + +
+
+ + {{/each}} + +
+ +
+
+
+
+
+
Andrey
+
+
+ {{{more_svg}}} +
+
+
+
+ {{#each chat_messages}} + {{{this.text}}} + +
+ {{{this.date}}} +
+ {{/each}} +
+
+
+
+ {{{svg_file}}} +
+ + + +
+ {{{svg_send}}} + +
+
+
+
+` diff --git a/src/pages/profile/profile.js b/src/pages/profile/profile.js new file mode 100644 index 000000000..465299c99 --- /dev/null +++ b/src/pages/profile/profile.js @@ -0,0 +1,42 @@ +import Handlebars from "handlebars"; +import { template } from "./profile.tmpl.js"; +import { template_edit } from "./profile_edit.tmpl.js"; +import { template_edit_password } from "./profile_edit_password.tmpl.js"; +import {button_blue, button, button_blue_static} from "../../components/Button/buttons.js"; +import {svg_arrow_right, svg_send} from "../../components/Svg/svg.js"; + +const name = "Дмитрий"; + +export const label = ({text, url}) => Handlebars.compile(` +`)({text, url}) + +const params = [ + {name: "Почта", value: "pochta@yandex.ru", value_name: "email"}, + {name: "Логин", value: "ivanivanov", value_name: "login"}, + {name: "Имя", value: "Иван", value_name: "first_name"}, + {name: "Фамилия", value: "Иванов", value_name: "second_name"}, + {name: "Имя в чате", value: "Иван", value_name: "display_name"}, + {name: "Телефон", value: "+7 (909) 967 30 30", value_name: "phone"}, +]; + +const params_password = [ + {name: "Старый пароль", value: "", placeholder: "*******", value_name: "oldPassword"}, + {name: "Новый пароль", value: "", placeholder: "*********", value_name: "newPassword"}, + {name: "Повторите новый пароль", value: "", placeholder: "*********", value_name: "newPassword_2"}, +]; + +const saveButton = button_blue_static({ + url: "/profile", + text: "Сохранить", +}); + +export const showProfile = (edit = "") => { + if(edit === "edit") { + return Handlebars.compile(template_edit)({saveButton, params,name, svg_send: svg_send(28,28) }); + } else if(edit === "password") { + return Handlebars.compile(template_edit_password)({saveButton, params: params_password,name, svg_send: svg_send(28,28) }); + } else { + return Handlebars.compile(template)({ params,name, svg_send: svg_send(28,28) }); + } +} + diff --git a/src/pages/profile/profile.less b/src/pages/profile/profile.less new file mode 100644 index 000000000..ef37055f8 --- /dev/null +++ b/src/pages/profile/profile.less @@ -0,0 +1,125 @@ +.page_profile { + display: flex; + flex-direction: row; + height: 100vh; + + .button_back { + width: 64px; + height: 100%; + background-color: #FBFBFB; + border-right: 1px solid #EAEAEA; + + display: flex; + justify-content: center; + align-items: center; + + &:hover { + background-color: #e8e5e5; + cursor: pointer; + } + } + + .profile_content { + width: 100%; + display: flex; + flex-direction: column; + align-items: center; + + .profile_logo { + background-color: #EFEFEF; + min-width: 130px; + min-height: 130px; + max-width: 130px; + border-radius: 50%; + margin-top: 60px; + margin-bottom: 21px; + } + + .profile_name { + font-size: 16px; + color: #1E1E1E; + font-weight: 600; + } + + .profile_params { + margin-top: 60px; + + .profile_param { + margin-top: 10px; + width: 510px; + display: flex; + flex-direction: row; + justify-content: space-between; + padding-bottom: 10px; + border-bottom: 1px solid #EAEAEA; + + &_name { + color: #1E1E1E; + font-size: 13px; + font-weight: 600; + } + &_value { + color: #999999; + font-size: 13px; + } + &_value input { + color: #999999; + font-size: 13px; + border: none; + text-align: right; + } + } + } + + .profile_buttons { + display: flex; + flex-direction: column; + margin-top: 60px; + align-items: center; + + &_button { + margin-top: 10px; + padding-bottom: 10px; + width: 510px; + font-size: 13px; + color: #3369F3; + border-bottom: 1px solid #EAEAEA; + text-decoration: none; + &:hover { + text-decoration: underline; + } + } + &_button__red { + border-bottom: none; + font-weight: 600; + color: #FF0000; + } + } + + } + + &__edit { + .profile_logo_input { + opacity: 0; + } + .profile_logo { + position: relative; + cursor: pointer; + + &:hover { + background-color: #000000; + &::before { + content: "Поменять аватар"; + color: #fff; + font-weight: 600; + z-index: 1; + position: absolute; + top: 50%; + left: 50%; + text-align: center; + transform: translate(-50%, -50%); + } + } + } + } +} \ No newline at end of file diff --git a/src/pages/profile/profile.tmpl.js b/src/pages/profile/profile.tmpl.js new file mode 100644 index 000000000..34581bdd9 --- /dev/null +++ b/src/pages/profile/profile.tmpl.js @@ -0,0 +1,30 @@ +export const template = ` +
+ +
+ {{{svg_send}}} +
+
+ +
+ +
{{name}}
+
+ + {{#each params}} +
+
{{{this.name}}}
+
{{{this.value}}}
+
+ {{/each}} +
+ +
+
+` + diff --git a/src/pages/profile/profile_edit.tmpl.js b/src/pages/profile/profile_edit.tmpl.js new file mode 100644 index 000000000..cecbe9964 --- /dev/null +++ b/src/pages/profile/profile_edit.tmpl.js @@ -0,0 +1,37 @@ +export const template_edit = ` +
+ +
+ {{{svg_send}}} +
+
+ +
+ + + + + +
{{name}}
+
+
+ + {{#each params}} +
+
{{{this.name}}}
+
+ +
+
+ {{/each}} +
+
+ {{{saveButton}}} +
+
+
+
+` + diff --git a/src/pages/profile/profile_edit_password.tmpl.js b/src/pages/profile/profile_edit_password.tmpl.js new file mode 100644 index 000000000..b40451e61 --- /dev/null +++ b/src/pages/profile/profile_edit_password.tmpl.js @@ -0,0 +1,35 @@ +export const template_edit_password = ` +
+ +
+ {{{svg_send}}} +
+
+ +
+ + + + + +
{{name}}
+
+
+ + {{#each params}} +
+
{{{this.name}}}
+
+ +
+
+ {{/each}} +
+
+ {{{saveButton}}} +
+
+
+
+` + diff --git a/src/pages/register/register.js b/src/pages/register/register.js new file mode 100644 index 000000000..5761f838e --- /dev/null +++ b/src/pages/register/register.js @@ -0,0 +1,64 @@ +import Handlebars from "handlebars"; +import { template } from "./register.tmpl.js"; +import { button_blue } from "../../components/Button/buttons.js"; +import { input } from "../../components/Input/input.js"; + + +const title = "Регистрация"; +const registerButton = button_blue({ + url: "/messages", + text: "Зарегистрироваться", +}); +const inp_login = input({ + text: "Логин", + type: "text", + name: "login", + placeholder: "ivanivavov", +}) + +const inp_email = input({ + text: "Почта", + type: "text", + name: "email", + placeholder: "ivanivavov@gmail.com", +}) + +const inp_name = input({ + text: "Имя", + type: "text", + name: "first_name", + placeholder: "Ivan", +}) + +const inp_last_name = input({ + text: "Фамилия", + type: "text", + name: "second_name", + placeholder: "Ivanov", +}) + +const inp_phone = input({ + text: "Телефон", + type: "tel", + name: "phone", + placeholder: "+7 (909) 967 30 30", +}) + +const inp_password = input({ + text: "Пароль", + type: "password", + name: "password", + placeholder: "***************", +}) + +const inp_password_2 = input({ + text: "Пароль (ещё раз)", + type: "password", + name: "password_2", + placeholder: "***************", +}) + +const inputs = [inp_email, inp_login, inp_name, inp_last_name,inp_phone, inp_password, inp_password_2]; + +export const showRegister = () => + Handlebars.compile(template)({ button: registerButton, title, inputs }); diff --git a/src/pages/register/register.tmpl.js b/src/pages/register/register.tmpl.js new file mode 100644 index 000000000..aa6bfb841 --- /dev/null +++ b/src/pages/register/register.tmpl.js @@ -0,0 +1,18 @@ +export const template = ` +
+
+

{{title}}

+
+
+ {{#each inputs}} + {{{this}}} + {{/each}} +
+ + {{{button}}} + Войти +
+ +
+
+` diff --git a/src/style.css b/src/style.css new file mode 100644 index 000000000..a796aa3a0 --- /dev/null +++ b/src/style.css @@ -0,0 +1,467 @@ +*:focus { + outline: none; +} +body { + margin: 0; + font-family: 'Inter', sans-serif; +} +*:focus { + outline: none; +} +body { + margin: 0; + font-family: 'Inter', sans-serif; +} +.messages { + display: flex; + height: 100vh; +} +.chats { + width: 24%; + border-right: 1px solid #EAEAEA; + min-width: 24%; + max-width: 24%; + overflow: hidden; +} +.chats .profile { + display: inline-block; + padding-right: 7.4%; + margin-top: 21px; + margin-bottom: 23px; + color: #999999; + font-size: 0.9375vw; + line-height: 0.9375vw; + text-align: right; + width: 100%; + box-sizing: border-box; + text-decoration: none; +} +.chats .profile:hover { + color: #726969; + text-decoration: underline; +} +.chats .search { + margin-left: 10px; + margin-right: 11px; + border-bottom: 1px solid #EAEAEA; + padding-bottom: 7px; +} +.chats .search input { + position: relative; + width: 100%; + background-color: #EFEFEF; + border-radius: 5px; + border: none; + height: 32px; + text-align: center; + font-size: 0.9375vw; + line-height: 0.9375vw; +} +.chat_list { + width: 100%; + display: flex; + flex-direction: column; +} +.chat { + display: flex; + justify-content: space-between; + margin-left: 10px; + padding-right: 10px; + padding-bottom: 12px; + border-bottom: 1px solid #EAEAEA; + padding-top: 12px; +} +.chat_active { + background-color: #E4EDFD; +} +.chat:hover { + background-color: #EFEFEF; + cursor: pointer; +} +.chat .image { + background-color: #EFEFEF; + width: 47px; + height: 47px; + border-radius: 50%; + margin-right: 10px; +} +.chat .data { + width: 77%; +} +.chat .name { + color: #1E1E1E; + font-size: 13px; + line-height: 13px; + font-weight: 600; + margin-bottom: 4px; +} +.chat .text { + color: #999999; + text-overflow: ellipsis; + overflow: hidden; + -webkit-line-clamp: 2; + display: -webkit-box; + -webkit-box-orient: vertical; + font-size: 13px; + line-height: 15px; + width: 99%; +} +.chat .text b { + color: #1E1E1E; + font-size: 12px; + font-weight: 600; +} +.chat .info { + display: flex; + flex-direction: column; + align-items: center; + justify-content: space-between; +} +.chat .info .date { + color: #999999; + font-size: 9px; +} +.chat .info .new { + width: 20px; + height: 20px; + background-color: #3369F3; + font-weight: 600; + color: #fff; + border-radius: 50%; + position: relative; +} +.chat .info .new p { + position: absolute; + font-size: 11px; + top: 50%; + left: 50%; + transform: translate(-50%, -50%); + padding: 0; + margin: 0; +} +.content { + width: 100%; + display: flex; + flex-direction: column; + justify-content: space-between; +} +.content .content_messages { + height: 100%; + display: flex; + flex-direction: column-reverse; +} +.content .chat_header { + position: relative; + margin-left: 20px; + margin-right: 20px; + height: 54px; + border-bottom: 1px solid #EAEAEA; + display: flex; + align-items: center; + justify-content: center; +} +.content .chat_header .more { + position: absolute; + right: 11px; + top: 20px; + width: 10px; + padding-left: 10px; +} +.content .chat_header .more:hover { + cursor: pointer; +} +.content .chat_header .more:hover path { + color: red; + fill: #e80909; +} +.content .chat_header .chat_header_info { + display: flex; + flex-direction: row; + align-items: center; +} +.content .chat_header .chat_header_info .chat_header_name { + margin-left: 10px; + font-size: 13px; + font-weight: 600; +} +.content .chat_header .chat_header_info .image { + background-color: #EFEFEF; + width: 34px; + height: 34px; + border-radius: 50%; +} +.content .chat_bottom { + border-top: 1px solid #EAEAEA; + height: 54px; + margin-left: 20px; + margin-right: 20px; + display: flex; + flex-direction: row; + justify-content: space-between; + box-sizing: border-box; + min-height: 54px; + max-height: 54px; + align-items: center; +} +.content .chat_bottom .file, +.content .chat_bottom .send { + cursor: pointer; +} +.content .chat_bottom .file:hover, +.content .chat_bottom .send:hover { + fill: red; +} +.content .chat_bottom .send_area { + border-radius: 30px; + font-size: 12px; + color: #999999; + padding: 10px 20px; + background-color: #EFEFEF; + width: 100%; + margin-right: 10px; + margin-left: 10px; + border: none; +} +.content .content_messages_message { + display: flex; + flex-direction: column-reverse; + margin-bottom: 30px; + margin-left: 20px; + padding: 11px; + max-width: 50%; + min-width: 404px; + background-color: #F8F8F8; + border-top-right-radius: 10px; + border-bottom-right-radius: 10px; + position: relative; +} +.content .content_messages_message .time { + position: absolute; + bottom: 10px; + right: 10px; + color: #999999; + font-size: 9px; +} +.page_profile { + display: flex; + flex-direction: row; + height: 100vh; +} +.page_profile .button_back { + width: 64px; + height: 100%; + background-color: #FBFBFB; + border-right: 1px solid #EAEAEA; + display: flex; + justify-content: center; + align-items: center; +} +.page_profile .button_back:hover { + background-color: #e8e5e5; + cursor: pointer; +} +.page_profile .profile_content { + width: 100%; + display: flex; + flex-direction: column; + align-items: center; +} +.page_profile .profile_content .profile_logo { + background-color: #EFEFEF; + min-width: 130px; + min-height: 130px; + max-width: 130px; + border-radius: 50%; + margin-top: 60px; + margin-bottom: 21px; +} +.page_profile .profile_content .profile_name { + font-size: 16px; + color: #1E1E1E; + font-weight: 600; +} +.page_profile .profile_content .profile_params { + margin-top: 60px; +} +.page_profile .profile_content .profile_params .profile_param { + margin-top: 10px; + width: 510px; + display: flex; + flex-direction: row; + justify-content: space-between; + padding-bottom: 10px; + border-bottom: 1px solid #EAEAEA; +} +.page_profile .profile_content .profile_params .profile_param_name { + color: #1E1E1E; + font-size: 13px; + font-weight: 600; +} +.page_profile .profile_content .profile_params .profile_param_value { + color: #999999; + font-size: 13px; +} +.page_profile .profile_content .profile_params .profile_param_value input { + color: #999999; + font-size: 13px; + border: none; + text-align: right; +} +.page_profile .profile_content .profile_buttons { + display: flex; + flex-direction: column; + margin-top: 60px; + align-items: center; +} +.page_profile .profile_content .profile_buttons_button { + margin-top: 10px; + padding-bottom: 10px; + width: 510px; + font-size: 13px; + color: #3369F3; + border-bottom: 1px solid #EAEAEA; + text-decoration: none; +} +.page_profile .profile_content .profile_buttons_button:hover { + text-decoration: underline; +} +.page_profile .profile_content .profile_buttons_button__red { + border-bottom: none; + font-weight: 600; + color: #FF0000; +} +.page_profile__edit .profile_logo_input { + opacity: 0; +} +.page_profile__edit .profile_logo { + position: relative; + cursor: pointer; +} +.page_profile__edit .profile_logo:hover { + background-color: #000000; +} +.page_profile__edit .profile_logo:hover::before { + content: "Поменять аватар"; + color: #fff; + font-weight: 600; + z-index: 1; + position: absolute; + top: 50%; + left: 50%; + text-align: center; + transform: translate(-50%, -50%); +} +.error_page { + width: 100vw; + height: 100vh; + display: flex; + flex-direction: column; + align-items: center; + position: relative; + justify-content: flex-start; +} +.error_page h1 { + font-size: 120px; + color: #1E1E1E; + margin-top: 150px; + margin-bottom: 50px; +} +.error_page p { + font-size: 20px; + color: #1E1E1E; +} +.error_page a { + color: #3369F3; + font-size: 24px; + position: absolute; + bottom: 50%; + transform: translateY(-50%); + text-decoration: none; +} +.error_page a:hover { + color: #2a56c5; +} +.rotate_svg_180 > svg { + transform: rotate(180deg); +} +.form { + width: 340px; + height: 450px; + position: absolute; + top: 50%; + left: 50%; + transform: translate(-50%, -50%); + border-radius: 12px; + /* shadow */ + -webkit-box-shadow: 0px 0px 16px 0px rgba(34, 60, 80, 0.2); + -moz-box-shadow: 0px 0px 16px 0px rgba(34, 60, 80, 0.2); + box-shadow: 0px 0px 16px 0px rgba(34, 60, 80, 0.2); +} +.form a { + font-size: 11px; + color: #3369F3; + text-align: center; + position: absolute; + bottom: 30px; + text-decoration: none; + width: 100%; +} +.form a:hover { + text-decoration: underline; +} +.form h1 { + color: #1E1E1E; + font-size: 20px; + line-height: 20px; + text-align: center; + margin-top: 50px; + margin-bottom: 40px; +} +.from__high { + height: 615px; +} +.inputs .input { + margin-left: 30px; + margin-right: 30px; + border-bottom: 1px solid #3369F3; + margin-top: 16px; + height: 36px; +} +.inputs .input .name { + color: #999999; + font-size: 9px; + line-height: 9px; + margin-bottom: 8px; +} +.inputs .input input { + color: #1E1E1E; + font-size: 13px; + margin-bottom: 7px; + border: none; + width: 100%; + font-weight: 600; + height: 13px; + padding: 0; +} +.button { + cursor: pointer; + margin-left: 30px; + width: 280px; + height: 37px; + border: none; + border-radius: 13px; + background-color: #7CDC85; + color: #FFFFFF; + font-size: 13px; +} +.button:hover { + background-color: #66bb6e; +} +.button__absolute { + position: absolute; + bottom: 55px; +} +.button__blue { + background-color: #466FDA; +} +/*# sourceMappingURL=style.css.map */ \ No newline at end of file diff --git a/src/style.css.map b/src/style.css.map new file mode 100644 index 000000000..b09872ec3 --- /dev/null +++ b/src/style.css.map @@ -0,0 +1 @@ +{"version":3,"sources":["style.less","pages/messages/messages.less","pages/profile/profile.less","pages/errors/style.less"],"names":[],"mappings":"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","file":"style.css"} \ No newline at end of file diff --git a/src/style.less b/src/style.less new file mode 100644 index 000000000..6fb9c63dd --- /dev/null +++ b/src/style.less @@ -0,0 +1,114 @@ +*:focus { + outline: none; +} + +body { + margin: 0; + font-family: 'Inter', sans-serif; +} + +// imports +@import "./pages/messages/messages.less"; +@import "./pages/profile/profile.less"; +@import "./pages/errors/style.less"; + +.rotate_svg_180 > svg { + transform: rotate(180deg); +} + +.form { + width: 340px; + height: 450px; + position: absolute; + top: 50%; + left: 50%; + transform: translate(-50%, -50%); + border-radius: 12px; + + /* shadow */ + -webkit-box-shadow: 0px 0px 16px 0px rgba(34, 60, 80, 0.2); + -moz-box-shadow: 0px 0px 16px 0px rgba(34, 60, 80, 0.2); + box-shadow: 0px 0px 16px 0px rgba(34, 60, 80, 0.2); + + a { + font-size: 11px; + color: #3369F3; + text-align: center; + position: absolute; + bottom: 30px; + text-decoration: none; + width: 100%; + + &:hover { + text-decoration: underline; + } + } + + h1 { + color: #1E1E1E; + font-size: 20px; + line-height: 20px; + text-align: center; + margin-top: 50px; + margin-bottom: 40px; + } +} + +.from__high { + height: 615px; +} + +.inputs { + + .input { + margin-left: 30px; + margin-right: 30px; + border-bottom: 1px solid #3369F3; + margin-top: 16px; + height: 36px; + + .name { + color: #999999; + font-size: 9px; + line-height: 9px; + margin-bottom: 8px; + } + + input { + color: #1E1E1E; + font-size: 13px; + margin-bottom: 7px; + border: none; + width: 100%; + font-weight: 600; + height: 13px; + padding: 0; + } + } +} + +.button { + cursor: pointer; + margin-left: 30px; + width: 280px; + height: 37px; + border: none; + border-radius: 13px; + background-color: #7CDC85; + color: #FFFFFF; + font-size: 13px; + + &:hover { + background-color: #66bb6e; + } +} + + +.button__absolute { + position: absolute; + bottom: 55px; +} + +.button__blue { + background-color: #466FDA; +} \ No newline at end of file diff --git a/src/units/mydash/util.js b/src/units/mydash/util.js new file mode 100644 index 000000000..77389a93c --- /dev/null +++ b/src/units/mydash/util.js @@ -0,0 +1,82 @@ +function identity(value) { + return value; +} + +function rangeRight(start, end, step) { + return range(start, end, step, true); +} + +function range(start, end, step, isRight) { + let newArr = []; + if(start !== undefined && end === undefined && step === undefined) { + if(start < 0) { + for (let p = 0; p > start; p--) { + newArr.push(p); + } + } else { + for (let p = 0; p < start; p++) { + newArr.push(p); + } + } + + return isRight ? newArr.reverse() : newArr; + } else if(start !== undefined && end !== undefined && step === undefined) { + for (let p = start; p < end; p++) { + newArr.push(p); + } + return isRight ? newArr.reverse() : newArr; + } else if(start !== undefined && end !== undefined && step !== undefined) { + for (let p = start; p < end; p+=step) { + newArr.push(p); + } + return isRight ? newArr.reverse() : newArr; + } else { + return []; + } +} + + +function last(arr) { + if(arr.length > 0) + return arr[arr.length - 1]; + + return undefined; +} + +function first(arr) { + if(arr.length > 0) + return arr[0]; + + return undefined; +} + +function isEmpty(value) { + if(value !== undefined && value !== null) { + if(Array.isArray(value)) { + return false; + } else if(typeof value === "object" && Object.keys(value).length > 0) { + return false; + } else if(typeof value === "string" && value !== "") { + return false; + } else if((value.constructor === Map || value.constructor === Set) && value.size > 0) { + return false; + } + } + + return true; +} + + + +console.log(isEmpty(null)); // => true +console.log(isEmpty(true)); // => true +console.log(isEmpty(1)); // => true +console.log(isEmpty([1, 2, 3])); // => false +console.log(isEmpty({ 'a': 1 })); // => false +console.log(isEmpty('123')); // => false +console.log(isEmpty(123)); // => true +console.log(isEmpty('')); // => true +console.log(isEmpty(0)); // => true +console.log(isEmpty(undefined)); // => true +console.log(isEmpty(new Map([['1', 'str1'], [1, 'num1'], [true, 'bool1']]))); // => false +console.log(isEmpty(new Set(['value1', 'value2', 'value3']))); // => false diff --git a/vite.config.js b/vite.config.js new file mode 100644 index 000000000..b6bb4e2d2 --- /dev/null +++ b/vite.config.js @@ -0,0 +1,24 @@ +import {defineConfig} from 'vite' +import handlebars from 'vite-plugin-handlebars'; + + +export default defineConfig({ + root: "./src", + build: { + rollupOptions: { + input: './src/index.html', + output: + { + format: 'es', + strict: false, + dir: 'dist/', + entryFileNames: `assets/[name].js`, + chunkFileNames: `assets/[name].js`, + assetFileNames: `assets/[name].[ext]`, + } + } + }, + plugins: [ + handlebars(), + ], +}) \ No newline at end of file