diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..4cb7545 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "damper.mjs"] + path = damper.mjs + url = https://git.svoboda.works/mirzaev/damper.mjs diff --git a/README.md b/README.md index 8ca9dee..df1c942 100755 --- a/README.md +++ b/README.md @@ -1,2 +1,2 @@ -# brainrot - +# Steal Brainrot +Telegram game chat-robot diff --git a/author/project/system/localizations/english.php b/author/project/system/localizations/english.php deleted file mode 100644 index a715895..0000000 --- a/author/project/system/localizations/english.php +++ /dev/null @@ -1,6 +0,0 @@ - '' -] \ No newline at end of file diff --git a/author/project/system/localizations/russian.php b/author/project/system/localizations/russian.php deleted file mode 100644 index a715895..0000000 --- a/author/project/system/localizations/russian.php +++ /dev/null @@ -1,6 +0,0 @@ - '' -] \ No newline at end of file diff --git a/author/project/system/models/enumerations/language.php b/author/project/system/models/enumerations/language.php deleted file mode 100755 index d4999cf..0000000 --- a/author/project/system/models/enumerations/language.php +++ /dev/null @@ -1,62 +0,0 @@ - - * @author kodorvan - */ -enum language -{ - case en; - case ru; - - /** - * Label - * - * Initialize label of the language - * - * @param language|null language Language into which to translate - * - * @return string Translated label of the language - */ - public function label(?language $language = language::en): string - { - // Exit (success) - return match ($this) { - language::en => match ($language) { - language::en => 'English', - language::ru => 'Английский' - }, - language::ru => match ($language) { - language::en => 'Russian', - language::ru => 'Русский' - } - }; - } - - /** - * Flag - * - * Initialize the flag emoji of the language - * - * @return string The flag emoji of the language - */ - public function flag(): string - { - // Exit (success) - return match ($this) { - language::en => '🇺🇸', - language::ru => '🇷🇺' - }; - } -} diff --git a/composer.json b/composer.json index ae9766b..c1ab110 100755 --- a/composer.json +++ b/composer.json @@ -2,7 +2,7 @@ "name": "kodorvan/brainrot", "description": "", "homepage": "https://git.svoboda.works/kodorvan/brainrot", - "type": "site", + "type": "game", "keywords": [ "minimal", "baza" @@ -11,12 +11,12 @@ "license": "WTFPL", "authors": [ { - "name": "kodorvan", - "email": "kodorvan@gmail.com", - "homepage": "https://kodorvan.page", - "role": "Programmer" - } - ], + "name": "Arsen Mirzaev Tatyano-Muradovich", + "email": "arsen@mirzaev.sexy", + "homepage": "https://mirzaev.sexy", + "role": "Programmer" + } + ], "support": { "wiki": "https://git.svoboda.works/kodorvan/brainrot/wiki", "issues": "https://git.svoboda.works/kodorvan/brainrot/issues" @@ -27,7 +27,13 @@ "mirzaev/baza": "^3.3", "twig/twig": "^3.2", "twig/extra-bundle": "^3.7", - "twig/intl-extra": "^3.10" + "twig/intl-extra": "^3.10", + "mirzaev/languages": "^1.0", + "mirzaev/currencies": "^1.0", + "svoboda/time": "^1.0", + "badfarm/zanzara": "^0.9.1", + "nyholm/psr7": "^1.8", + "react/filesystem": "^0.1.2" }, "autoload": { "psr-4": { @@ -41,5 +47,11 @@ }, "scripts": { "pre-update-cmd": "./install.sh" + }, + "config": { + "allow-plugins": { + "php-http/discovery": true, + "wyrihaximus/composer-update-bin-autoload-path": true + } } } diff --git a/damper.mjs b/damper.mjs new file mode 160000 index 0000000..81d208b --- /dev/null +++ b/damper.mjs @@ -0,0 +1 @@ +Subproject commit 81d208b96470e6068e735f38ccfc0f941079c3a5 diff --git a/install.sh b/install.sh index a1114c0..d3edd56 100755 --- a/install.sh +++ b/install.sh @@ -1,10 +1,5 @@ -#!/bin/bash - -if [ -d author/project ]; then - mv author/project author/brainrot -fi - -if [ -d author ]; then - mv author kodorvan -fi +#!/bin/fish +if not test -L kodorvan/brainrot/system/public/js/modules/damper.mjs + ln -s ../../../../../../damper.mjs/damper.mjs kodorvan/brainrot/system/public/js/modules/damper.mjs +end diff --git a/author/project/system/controllers/core.php b/kodorvan/brainrot/system/controllers/core.php similarity index 93% rename from author/project/system/controllers/core.php rename to kodorvan/brainrot/system/controllers/core.php index 7447d3b..3514be4 100755 --- a/author/project/system/controllers/core.php +++ b/kodorvan/brainrot/system/controllers/core.php @@ -6,8 +6,10 @@ namespace kodorvan\brainrot\controllers; // Files of the project use kodorvan\brainrot\views\templater, - kodorvan\brainrot\models\core as models, - kodorvan\brainrot\models\enumerations\language; + kodorvan\brainrot\models\core as models; + +// Library for languages support +use mirzaev\languages\language; // Framework for PHP use mirzaev\minimal\core as minimal, @@ -28,7 +30,6 @@ use mirzaev\minimal\core as minimal, * * @license http://www.wtfpl.net/ Do What The Fuck You Want To Public License * @author Arsen Mirzaev Tatyano-Muradovich - * @author kodorvan */ class core extends controller { diff --git a/author/project/system/controllers/index.php b/kodorvan/brainrot/system/controllers/index.php similarity index 96% rename from author/project/system/controllers/index.php rename to kodorvan/brainrot/system/controllers/index.php index 7189d74..cab2e2d 100755 --- a/author/project/system/controllers/index.php +++ b/kodorvan/brainrot/system/controllers/index.php @@ -22,7 +22,6 @@ use mirzaev\minimal\http\enumerations\content, * * @license http://www.wtfpl.net/ Do What The Fuck You Want To Public License * @author Arsen Mirzaev Tatyano-Muradovich - * @author kodorvan */ final class index extends core { diff --git a/author/project/system/databases/.gitignore b/kodorvan/brainrot/system/databases/.gitignore similarity index 100% rename from author/project/system/databases/.gitignore rename to kodorvan/brainrot/system/databases/.gitignore diff --git a/kodorvan/brainrot/system/localizations/english.php b/kodorvan/brainrot/system/localizations/english.php new file mode 100644 index 0000000..a3ef545 --- /dev/null +++ b/kodorvan/brainrot/system/localizations/english.php @@ -0,0 +1,76 @@ + 'Svoboda', + 'kodorvan' => 'Kodorvan', + 'brainrot' => 'Steal Brainrot', + 'empty' => 'Empty', + 'yes' => 'Yes', + 'no' => 'No', + + // Main menu + 'menu_title' => 'Main menu', + 'menu_accounts' => 'Accounts', + + // Account + 'account_title' => 'Account', + 'account_authorized_system' => 'Access to the system', + 'account_authorized_settings' => 'Access to settings', + 'account_authorized_system_accounts' => 'System access to accounts management', + 'account_authorized_system_settings' => 'System access to the system settings', + 'account_button_localizations' => 'Localizations', + 'account_localization_create_failted_to_initialize_language' => 'Failed to initialize language', + + // Language setting + 'settings_select_language_title' => 'Select language', + 'settings_select_language_description' => 'The selected language will be writed in your account settings', + 'settings_language_update_success' => 'Language replaced:', + 'settings_language_update_fail' => 'Failed to replace language', + + // Language selection + 'select_language_title' => 'Select language', + 'select_language_description' => 'The selected language will be used in the current process', + 'select_language_button_add' => 'Add a language', + + // Repository + 'repository_title' => 'Repository', + 'repository_text' => << 'The code', + 'repository_button_issues' => 'Issues', + 'repository_button_suggestions' => 'Suggestions', + + // Author + 'author_title' => 'Author', + 'author_text' => << 'Neurojournal', + 'author_button_projects' => 'Projects', + 'author_button_telegram' => 'Telegram', + 'author_button_twitter' => 'Twitter', + 'author_button_bluesky' => 'Bluesky', + 'author_button_bastyon' => 'Bastyon', + 'author_button_youtube_english' => 'YouTube', + 'author_button_youtube_russian' => 'YouTube', + 'author_button_message' => 'Send a message', + + // Authorization + 'not_authorized_system' => 'You do not have access to the system', + 'not_authorized_messages' => 'You do not have access to send messages', + 'not_authorized_joins' => 'You do not have access to joins', + 'not_authorized_settings' => 'You do not have access to the settings', + 'not_authorized_system_settings' => 'You do not have access to the system settings', + 'not_authorized_system_distributions' => 'You do not have access to distributions administration', + + // Other + 'why_so_shroomious' => 'why so shroomious' +]; diff --git a/kodorvan/brainrot/system/localizations/russian.php b/kodorvan/brainrot/system/localizations/russian.php new file mode 100644 index 0000000..b15b1c7 --- /dev/null +++ b/kodorvan/brainrot/system/localizations/russian.php @@ -0,0 +1,80 @@ + 'Свобода', + 'kodorvan' => 'Кодорвань', + 'brainrot' => 'Укради Брейнрот', + 'empty' => 'Пусто', + 'yes' => 'Да', + 'no' => 'Нет', + + // Main menu + 'menu_title' => 'Главное меню', + 'menu_accounts' => 'Аккаунты', + + // Аккаунт + 'account_title' => 'Аккаунт', + 'account_authorized_system' => 'Доступ к системе', + 'account_authorized_messages' => 'Доступ к сообщениям', + 'account_authorized_joins' => 'Доступ к вступлениям', + 'account_authorized_settings' => 'Доступ к изменению настроек', + 'account_authorized_system_accounts' => 'Системный доступ к управлению аккаунтами', + 'account_authorized_system_distributions' => 'Системный доступ к управлению дистрибутивами', + 'account_authorized_system_members' => 'Системный доступ к управлению участниками дистрибутивов', + 'account_authorized_system_settings' => 'Системный доступ к системным настройкам', + 'account_button_localizations' => 'Локализации', + 'account_localization_create_failted_to_initialize_language' => 'Не удалось инициализировать язык', + + // Настройки языка + 'settings_select_language_title' => 'Выбери язык', + 'settings_select_language_description' => 'Выбранный язык будет записан в настройки аккаунта', + 'settings_language_update_success' => 'Язык заменён:', + 'settings_language_update_fail' => 'Не удалось заменить язык', + + // Выбор языка + 'select_language_title' => 'Выбери язык', + 'select_language_description' => 'Выбранный язык будет использован в текущем процессе', + 'select_language_button_add' => 'Добавить язык', + + // Репозиторий + 'repository_title' => 'Репозиторий', + 'repository_text' => << 'Код', + 'repository_button_issues' => 'Проблемы', + 'repository_button_suggestions' => 'Предложения', + + // Автор + 'author_title' => 'Автор', + 'author_text' => << 'Нейрожурнал', + 'author_button_projects' => 'Проекты', + 'author_button_telegram' => 'Телеграм', + 'author_button_twitter' => 'Twitter', + 'author_button_bluesky' => 'Bluesky', + 'author_button_bastyon' => 'Bastyon', + 'author_button_youtube_english' => 'YouTube', + 'author_button_youtube_russian' => 'YouTube', + 'author_button_message' => 'Отправить сообщение', + + // Авторизация + 'not_authorized_system' => 'У тебя нет доступа к системе', + 'not_authorized_messages' => 'У тебя нет доступа к сообщениям', + 'not_authorized_joins' => 'У тебя нет доступа к вступлениям', + 'not_authorized_settings' => 'У тебя нет доступа к настройкам', + 'not_authorized_system_settings' => 'У тебя нет доступа к системным настройкам', + 'not_authorized_system_distributions' => 'У тебя нет доступа к администрированию дистрибутивов', + + // Прочее + 'why_so_shroomious' => 'почему такой грибъёзный' +]; diff --git a/kodorvan/brainrot/system/models/account.php b/kodorvan/brainrot/system/models/account.php new file mode 100644 index 0000000..bf259f7 --- /dev/null +++ b/kodorvan/brainrot/system/models/account.php @@ -0,0 +1,201 @@ + + */ +final class account extends core +{ + /** + * File + * + * @var string $database Path to the database file + */ + protected string $file = DATABASES . DIRECTORY_SEPARATOR . 'accounts.baza'; + + /** + * Database + * + * @var database $database The database + */ + public protected(set) database $database; + + /** + * Constructor + * + * @return void + */ + public function __construct() + { + // Initializing the database + $this->database = new database() + ->encoding(encoding::utf8) + ->columns( + new column('identifier', type::integer_unsigned), + new column('identifier_telegram', type::long_long_unsigned), + new column('domain', type::string, ['length' => 32]), + new column('name_first', type::string, ['length' => 64]), + new column('name_second', type::string, ['length' => 64]), + new column('language', type::string, ['length' => 2]), + new column('robot', type::char), + new column('authorized_system', type::char), + new column('authorized_settings', type::char), + new column('authorized_system_accounts', type::char), + new column('authorized_system_settings', type::char), + new column('updated', type::integer_unsigned), + new column('created', type::integer_unsigned) + ) + ->connect($this->file); + } + + /** + * Initialize + * + * Searches for the account record in the database, and if it does not find it, it creates it + * + * @param telegram $telegram The telegram account + * + * @throws exception_runtime if update the account record in the database by the telegram account values + * @throws exception_runtime if failed to find the registered account + * @throws exception_runtime if failed to registrate the account + * + * @return record The account record from the database + */ + public function initialize(telegram $telegram): record + { + // Searching for the account in the database + $account = $this->database->read(filter: fn(record $record) => $record->identifier_telegram === $telegram->getId(), amount: 1)[0] ?? null; + + if ($account instanceof record) { + // Found the account record + + if ( + $account->name_first !== $telegram->getFirstName() || + $account->name_second !== $telegram->getLastName() || + $account->domain !== $telegram->getUsername() + ) { + // The telegram account was updated + + // Updating the account in the database + $updated = $this->database->read( + filter: fn(record $record) => $record->identifier_telegram === $telegram->getId(), + update: function (record &$record) use ($telegram){ + // Writing new values into the record + $record->name_first = $telegram->getFirstName(); + $record->name_second = $telegram->getLastName(); + $record->domain = $telegram->getUsername(); + $record->updated = svoboda::timestamp(); + }, + amount: 1 + )[0] ?? null; + + if ($updated instanceof record && $updated->values() !== $account->values()) { + // Updated the account in the database + + // Exit (success) + return $updated; + } else { + // Not updated the account in the database + + // Exit (fail) + throw new exception_runtime('Failed to update the account record in the database by the telegram account values'); + } + } + + // Exit (success) + return $account; + } else { + // Not found the account record + + if ($this->registrate($telegram)) { + // Registered the account + + // Searching for the registered account in the database + $account = $this->database->read(filter: fn(record $record) => $record->identifier_telegram === $telegram->getId(), amount: 1)[0] ?? null; + + if ($account instanceof record) { + // Found the registered account + + // Exit (success) + return $account; + } else { + // Not found the registered account + + // Exit (fail) + throw new exception_runtime('Failed to find the registered account'); + } + } else { + // Not registered the account + + // Exit (fail) + throw new exception_runtime('Failed to registrate the account'); + } + } + } + + /** + * Registrate + * + * Creates the account record in the database + * + * @param telegram $telegram The telegram account + * + * @return int|false The record identifier, if created + */ + public function registrate(telegram $telegram): int|false + { + // Initializing the identifier + $identifier = $this->database->count() + 1; + + // Initializing the record + $record = $this->database->record( + $identifier, + (int) $telegram->getId(), + (string) $telegram->getFirstName(), + (string) $telegram->getLastName(), + (string) $telegram->getUsername(), + (string) $telegram->getLanguageCode(), + (int) $telegram->isBot(), + 1, + 1, + 0, + 0, + svoboda::timestamp(), + svoboda::timestamp() + ); + + // Creating the record in the database + $created = $this->database->write($record); + + // Exit (success) + return $created ? $identifier : false; + } +} diff --git a/author/project/system/models/core.php b/kodorvan/brainrot/system/models/core.php similarity index 95% rename from author/project/system/models/core.php rename to kodorvan/brainrot/system/models/core.php index f3137d6..6631aee 100755 --- a/author/project/system/models/core.php +++ b/kodorvan/brainrot/system/models/core.php @@ -20,7 +20,6 @@ use exception; * * @license http://www.wtfpl.net/ Do What The Fuck You Want To Public License * @author Arsen Mirzaev Tatyano-Muradovich - * @author kodorvan */ class core extends model { diff --git a/kodorvan/brainrot/system/models/telegram/account.php b/kodorvan/brainrot/system/models/telegram/account.php new file mode 100644 index 0000000..44d3683 --- /dev/null +++ b/kodorvan/brainrot/system/models/telegram/account.php @@ -0,0 +1,34 @@ + + */ +final class account extends core +{ +} diff --git a/kodorvan/brainrot/system/models/telegram/commands.php b/kodorvan/brainrot/system/models/telegram/commands.php new file mode 100644 index 0000000..bf002a3 --- /dev/null +++ b/kodorvan/brainrot/system/models/telegram/commands.php @@ -0,0 +1,531 @@ + + */ +final class commands extends core +{ + /** + * Menu + * + * Responce for the commands: "/start", '/menu' + * + * @param context $context Request data from Telegram + * + * @return void + */ + public static function menu(context $context): void + { + // Initializing the account + $account = $context->get('account'); + + if ($account instanceof record) { + // Initialized the account + + // Initializing localization + $localization = $context->get('localization'); + + if ($localization) { + // Initialized localization + + // Initializing the title + $title = '📋 *' . $localization['menu_title'] . '*'; + + // Initializing accounts + $accounts = '*' . $localization['menu_accounts'] . ':* ' . ((new account)->database->count() ?? 0); + + + // Sending the message + $context->sendMessage( + << [ + 'inline_keyboard' => [ + [ + [ + 'text' => '🐣 ' . $localization['kodorvan'], + 'web_app' => [ + 'url' => 'https://brainrot.svoboda.works' + ] + ] + ] + ], + 'disable_notification' => true, + 'remove_keyboard' => true + ], + ] + ) + ->then(function (message $message) use ($context) { + // Sended the message + }); + } else { + // Not initialized localization + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize localization*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized the account + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize your Telegram account*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } + + /** + * Account + * + * Responce for the command: "/account" + * + * Sends information about account with menu + * + * @param context $context Request data from Telegram + * + * @return void + */ + public static function account(context $context): void + { + // Initializing the account + $account = $context->get('account'); + + if ($account instanceof record) { + // Initialized the account + + // Initializing localization + $localization = $context->get('localization'); + + if ($localization) { + // Initialized localization + + // Initializing title for the message + $title = '🫵 ' . $localization['account_title']; + + // Declaring buufer of rows about authorizations + $authorizations = ''; + + // Initializing rows about authorization + foreach ($account->values() as $key => $value) { + // Iterating over account parameters + + if (str_starts_with($key, 'authorized_')) { + // Iterating over account authorizations + + // Skipping system authorizations + if (str_starts_with($key, 'authorized_system_')) continue; + + // Writing into buffer of rows about authorizations + $authorizations .= ($value ? '✅' : '❎') . ' *' . ($localization["account_$key"] ?? $key) . ':* ' . ($value ? $localization['yes'] : $localization['no']) . "\n"; + } + } + + // Trimming the last line break character + $authorizations = trim($authorizations, "\n"); + + // Initializing the data export for the message + $export = '📤 ' . $localization['account_export']; + + // Initializing the data security for the message + $data = $localization['account_data']; + + // Initializing the data security repository for the message + $security = '📁 [' . $localization['account_security_repository'] . '](https://git.svoboda.works/mirzaev/security) \([' . $localization['account_security_repository_mirror_github'] . '](https://github.com/mature-woman/security)\)'; + + // Sending the message + $context->sendMessage( + << [ + 'remove_keyboard' => true, + 'disable_notification' => true + ], + 'link_preview_options' => [ + 'is_disabled' => true + ] + ] + ); + } else { + // Not initialized localization + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize localization*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized the account + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize your Telegram account*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } + + /** + * Language + * + * Responce for the command: "/language" + * + * Send the language selection menu + * + * @param context $context Request data from Telegram + * + * @return void + */ + public static function language(context $context): void + { + // Initializing the account + $account = $context->get('account'); + + if ($account instanceof record) { + // Initialized the account + + // Initializing language + $language = $context->get('language'); + + if ($language instanceof language) { + // Initialized language + + // Initializing localization + $localization = $context->get('localization'); + + if ($localization) { + // Initialized localization + + // Sending the language selection + process_language_select::menu( + context: $context, + prefix: 'settings_language_', + title: '🌏 *' . $localization['settings_select_language_title'] . '*', + description: '🌏 *' . $localization['settings_select_language_description'] . '*' + ); + } else { + // Not initialized localization + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize localization*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized language + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize language*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized the account + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize your Telegram account*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } + + /** + * Repository + * + * Responce for the command: "/repository" + * + * Sends information about project and menu + * + * @param context $context Request data from Telegram + * + * @return void + */ + public static function repository(context $context): void + { + // Initializing the account + $account = $context->get('account'); + + if ($account instanceof record) { + // Initialized the account + + // Initializing localization + $localization = $context->get('localization'); + + if ($localization) { + // Initialized localization + + // Initializing title of the message + $title = '🏛️ ' . $localization['repository_title']; + + // Sending the message + $context->sendMessage($title . "\n\n" . $localization['repository_text'], [ + 'reply_markup' => [ + 'inline_keyboard' => [ + [ + [ + 'text' => '🏛️ ' . $localization['repository_button_code'], + 'url' => 'https://git.mirzaev.sexy/kodorvan/brainrot' + ] + ], + [ + [ + 'text' => '⚠️ ' . $localization['repository_button_issues'], + 'url' => 'https://git.mirzaev.sexy/kodorvan/brainrot/issues' + ], + [ + 'text' => '🌱 ' . $localization['repository_button_suggestions'], + 'url' => 'https://git.mirzaev.sexy/kodorvan/brainrot/issues' + ] + ] + ], + 'remove_keyboard' => true, + 'disable_notification' => true + ], + 'link_preview_options' => [ + 'is_disabled' => true + ] + ]); + } else { + // Not initialized localization + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize localization*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized the account + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize your Telegram account*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } + + /** + * Author + * + * Responce for the command: "/author" + * + * Sends + * + * @param context $context Request data from Telegram + * + * @return void + */ + public static function author(context $context): void + { + // Initializing the account + $account = $context->get('account'); + + if ($account instanceof record) { + // Initialized the account + + // Initializing localization + $localization = $context->get('localization'); + + if ($localization) { + // Initialized localization + + // Initializing title of the message + $title = '👽 ' . $localization['author_title']; + + // Sending the message + $context->sendMessage($title . "\n\n" . $localization['author_text'], [ + 'reply_markup' => [ + 'inline_keyboard' => [ + [ + [ + 'text' => '📚 ' . $localization['author_button_neurojournal'], + 'url' => 'https://mirzaev.sexy' + ], + [ + 'text' => '🤟 ' . $localization['author_button_projects'], + 'url' => 'https://git.svoboda.works/mirzaev?tab=activity' + ] + ], + [ + [ + 'text' => '📣 ' . $localization['author_button_telegram'], + 'url' => 'https://t.me/blog_mirzaev_sexy' + ], + [ + 'text' => '✖️ ' . $localization['author_button_twitter'], + 'url' => 'https://x.com/mirzaev_sexy' + ], + [ + 'text' => '🦋 ' . $localization['author_button_bluesky'], + 'url' => 'https://bsky.app/profile/mirzaev.bsky.social' + ], + [ + 'text' => '⛓️ ' . $localization['author_button_bastyon'], + 'url' => 'https://bsky.app/profile/mirzaev.bsky.social' + ] + ], + [ + [ + 'text' => '🇺🇸 ' . $localization['author_button_youtube_english'], + 'url' => 'https://www.youtube.com/@MIRZAEV' + ], + [ + 'text' => '🇷🇺 ' . $localization['author_button_youtube_russian'], + 'url' => 'https://www.youtube.com/@MIRZAEV' + ] + ], + [ + [ + 'text' => '✉️ ' . $localization['author_button_message'], + 'url' => 'https://t.me/mirzaev_sexy' + ] + ] + ], + 'remove_keyboard' => true, + 'disable_notification' => true + ], + 'link_preview_options' => [ + 'is_disabled' => true + ] + ]); + } else { + // Not initialized localization + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize localization*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized the account + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize your Telegram account*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } + + /** + * Society + * + * Responce for the command: "/society" + * + * Sends the "mushroom" image and the localized text "why so shroomious" + * + * @param context $context Request data from Telegram + * + * @return void + */ + public static function society(context $context): void + { + // Initializing the account + $account = $context->get('account'); + + if ($account instanceof record) { + // Initialized the account + + // Initializing localization + $localization = $context->get('localization'); + + if ($localization) { + // Initialized localization + + // Sending the message + $context->sendPhoto( + new file_input(STORAGE . DIRECTORY_SEPARATOR . 'images' . DIRECTORY_SEPARATOR . 'mushroom.jpg'), + [ + 'caption' => $localization['why_so_shroomious'], + 'disable_notification' => true + ] + ); + } else { + // Not initialized localization + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize localization*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized the account + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize your Telegram account*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } +} diff --git a/kodorvan/brainrot/system/models/telegram/middlewares.php b/kodorvan/brainrot/system/models/telegram/middlewares.php new file mode 100644 index 0000000..f0ae004 --- /dev/null +++ b/kodorvan/brainrot/system/models/telegram/middlewares.php @@ -0,0 +1,373 @@ + + */ +final class middlewares extends core +{ + /** + * Account (middleware) + * + * Initialize or registrate the account and write it to the `account` variable inside the `$context` + * + * @param context $context + * @param node $next + * + * @return void + */ + public static function account(context $context, node $next): void + { + // Is the process stopped? + if ($context->get('stop')) return; + + // Initializing the telegram account + $telegram = $context->getEffectiveUser(); + + // Initializing the account + /* $account = new account()->initialize($telegram); */ + $account = (new account())->initialize($telegram); + + if ($account instanceof record) { + // Initialized the account + + // Writing the account into the context variable + $context->set('account', $account); + + // Continuation of the process + $next($context); + } else { + // Not initialized the account + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize your Telegram account*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } + + /** + * Language (middleware) + * + * Implement the account language + * + * @param context $context + * @param node $next + * + * @return void + */ + public static function language(context $context, node $next): void + { + // Is the process stopped? + if ($context->get('stop')) return; + + // Initializing the account + $account = $context->get('account'); + + if ($account instanceof record) { + // Initialized the account + + if ($account->language) { + // Initialized the language parameter + + try { + // Writing the account language into the context variable + $context->set('language', language::{$account->language}); + } catch (error $error) { + // Not initialized the language + + // Writing the default language into the context variable + $context->set('language', language::en); + } + } else { + // Not initialized the language parameter + + // Writing the default language into the context variable + $context->set('language', language::en); + } + + // Continuation of the process + $next($context); + } else { + // Not initialized the account + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize your Telegram account*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } + + /** + * Localization (middleware) + * + * Implement the account language and initialize the localization file + * + * @param context $context + * @param node $next + * + * @return void + */ + public static function localization(context $context, node $next): void + { + // Is the process stopped? + if ($context->get('stop')) return; + + // Initializing the account + $account = $context->get('account'); + + if ($account instanceof record) { + // Initialized the account + + // Initializing the language + $language = $context->get('language'); + + if ($language instanceof language) { + // Initialized the language + + // Initializing path to the localization file + $file = LOCALIZATIONS . DIRECTORY_SEPARATOR . strtolower($language->label()) . '.php'; + + if (file_exists($file) && is_readable($file)) { + // Found the localization file + + // Initializing localization + $localization = require($file); + + if (is_array($localization)) { + // Initialized localization + + // Writing localization into the context variable + $context->set('localization', $localization); + + // Continuation of the process + $next($context); + } else { + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize localization*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not found the localization file + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize the localization file*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized language + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize language*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized the account + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize your Telegram account*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } + + /** + * Settings (middleware) + * + * Check the account for access to the settings + * + * @param context $context + * @param node $next + * + * @return void + */ + public static function settings(context $context, node $next): void + { + // Is the process stopped? + if ($context->get('stop')) return; + + // Initializing the account + $account = $context->get('account'); + + if ($account instanceof record) { + // Initialized the account + + if ($account->authorized_settings) { + // Authorized the account to the settings + + // Continuation of the process + $next($context); + } else { + // Not authorized the account to the settings + + // Initializing localization + $localization = $context->get('localization'); + + if ($localization) { + // Initialized localization + + // Sending the message + $context->sendMessage('⛔ *' . $localization['not_authorized_settings'] . '*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + + // Stopping the process + $context->set('stop', true); + } else { + // Not initialized localization + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize localization*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } + } else { + // Not initialized the account + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize your Telegram account*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } + + /** + * System settings (middleware) + * + * Check the account for access to the system settings + * + * @param context $context + * @param node $next + * + * @return void + */ + public static function system_settings(context $context, node $next): void + { + // Is the process stopped? + if ($context->get('stop')) return; + + // Initializing the account + $account = $context->get('account'); + + if ($account instanceof record) { + // Initialized the account + + if ($account->authorized_system_settings) { + // Authorized the account to the system settings + + // Continuation of the process + $next($context); + } else { + // Not authorized the account to the system settings + + // Initializing localization + $localization = $context->get('localization'); + + if ($localization) { + // Initialized localization + + // Sending the message + $context->sendMessage('⛔ *' . $localization['not_authorized_system_settings'] . '*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + + // Stopping the process + $context->set('stop', true); + } else { + // Not initialized localization + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize localization*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } + } else { + // Not initialized the account + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize your Telegram account*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } +} diff --git a/kodorvan/brainrot/system/models/telegram/processes/language/select.php b/kodorvan/brainrot/system/models/telegram/processes/language/select.php new file mode 100644 index 0000000..13cfa51 --- /dev/null +++ b/kodorvan/brainrot/system/models/telegram/processes/language/select.php @@ -0,0 +1,152 @@ + + */ +final class select extends core +{ + /** + * Language + * + * Send the language choose menu + * + * @param context $context Request data from Telegram + * @param string $prefix Prefix for 'callback_data' (`$prefix . $language->name`) + * @param string $title Title of the message + * @param string $description Description of the message + * @param array $exclude Languages that will be excluded ['ru', 'en'...] + * + * @return void + */ + public static function menu(context $context, string $prefix, string $title, string $description, array $exclude = []): void + { + // Initializing the account + $account = $context->get('account'); + + if ($account instanceof record) { + // Initialized the account + + // Initializing language + $language = $context->get('language'); + + if ($language) { + // Initialized language + + // Initializing localization + $localization = $context->get('localization'); + + if ($localization) { + // Initialized localization + + // Declaring the buffer of generated keyboard with languages + $keyboard = []; + + // Initializing the iterator of rows + $row = 0; + + // Initializing buffer of languages + $languages = language::cases(); + + // Deleting the actual language from buffer of languages + unset($languages[array_search($language, $languages, strict: true)]); + + // Sorting buffer of languages by the actual language + $languages = [$language, ...$languages]; + + foreach ($languages as $language) { + // Iterating over languages + + // Skipping excluded languages + if (array_search($language->name, $exclude, strict: true) !== false) continue; + + // Initializing the row + $keyboard[$row] ??= []; + + // Writing the language choose button into the buffer of generated keyboard with languages + $keyboard[$row][] = [ + 'text' => ($language->flag() ? $language->flag() . ' ' : '') . $language->label($language), + 'callback_data' => $prefix . $language->name + ]; + + // When reaching 4 buttons in a row, move to the next row + if (count($keyboard[$row]) === 4) ++$row; + } + + // Writing the button for helping lozalizing + $keyboard[$row === 0 && empty($keyboard[0]) ? 0 : ++$row] = [ + [ + 'text' => '🗂 ' . $localization['select_language_button_add'], + 'url' => 'https://git.svoboda.works/kodorvan/brainrot/src/branch/stable/kodorvan/brainrot/system/localizations' + ] + ]; + + // Sending the message + $context->sendMessage( + $title ?? '🌏 *' . $localization['select_language_title'] . "*\n" . ($description ?? $localization['select_language_description']), + [ + 'reply_markup' => [ + 'inline_keyboard' => $keyboard, + 'disable_notification' => true + ], + ] + ); + } else { + // Not initialized localization + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize localization*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized language + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize language*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized the account + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize your Telegram account*') + ->then(function (message $message) use ($context) { + // Sended the message + + // Ending the conversation process + $context->endConversation(); + }); + } + } +} diff --git a/kodorvan/brainrot/system/models/telegram/settings.php b/kodorvan/brainrot/system/models/telegram/settings.php new file mode 100644 index 0000000..37a1b17 --- /dev/null +++ b/kodorvan/brainrot/system/models/telegram/settings.php @@ -0,0 +1,158 @@ + + */ +final class settings extends core +{ + /** + * Language + * + * Write language into the account record + * + * @param context $context Request data from Telegram + * @param language $language The language + * + * @return void + */ + public static function language(context $context, language $language): void + { + // Initializing the account + $account = $context->get('account'); + + if ($account instanceof record) { + // Initialized the account + + // Initializing localization + $localization = $context->get('localization'); + + if ($localization) { + // Initialized localization + + // Initializing the account model + $model = new account(); + + // Updating the account in the database + $updated = $model->database->read( + filter: fn(record $record) => $record->identifier === $account->identifier, + update: function (record &$record) use ($language) { + // Writing new language value into the record + $record->language = $language->name; + }, + amount: 1 + )[0] ?? null; + + if ($updated instanceof record) { + // Updated the account in the database + + // Writing the updated account into the context variable + $context->set('account', $updated); + + middlewares::language($context, new node(function (context $context) use ($account, $updated) { + // Updated language + + middlewares::localization($context, new node(function (context $context) use ($account, $updated) { + // Updated localization + + // Initializing localization + $localization = $context->get('localization'); + + if ($localization) { + // Initialized localization + + try { + // Initializing the old language + $old = language::{$account->language}; + + // Initializing the new language + $new = language::{$updated->language}; + + // Sending the message + $context->sendMessage('✅ *' . $localization['settings_language_update_success'] . '* ' . ($old->flag() ? $old->flag() . ' ' : '') . $old->label($new) . ' → *' . ($new->flag() ? $new->flag() . ' ' : '') . $new->label($new) . '*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } catch (error $error) { + // Failed to send the message about language update + + // Sending the message + $context->sendMessage('❎ *' . $localization['settings_language_update_fail']) + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized localization + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize localization*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + })); + })); + } else { + // Not updated the account in the database + + // Sending the message + $context->sendMessage('❎ *' . $localization['settings_language_update_fail']) + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized localization + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize localization*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } else { + // Not initialized the account + + // Sending the message + $context->sendMessage('⚠️ *Failed to initialize your Telegram account*') + ->then(function (message $message) use ($context) { + // Ending the conversation process + $context->endConversation(); + }); + } + } +} diff --git a/author/project/system/models/traits/files.php b/kodorvan/brainrot/system/models/traits/files.php similarity index 97% rename from author/project/system/models/traits/files.php rename to kodorvan/brainrot/system/models/traits/files.php index bb8ccaf..a70c411 100755 --- a/author/project/system/models/traits/files.php +++ b/kodorvan/brainrot/system/models/traits/files.php @@ -18,7 +18,6 @@ use exception; * * @license http://www.wtfpl.net/ Do What The Fuck You Want To Public License * @author Arsen Mirzaev Tatyano-Muradovich - * @author kodorvan */ trait files { diff --git a/author/project/system/public/css/fonts/dejavu.css b/kodorvan/brainrot/system/public/css/fonts/dejavu.css similarity index 100% rename from author/project/system/public/css/fonts/dejavu.css rename to kodorvan/brainrot/system/public/css/fonts/dejavu.css diff --git a/author/project/system/public/css/fonts/fira.css b/kodorvan/brainrot/system/public/css/fonts/fira.css similarity index 100% rename from author/project/system/public/css/fonts/fira.css rename to kodorvan/brainrot/system/public/css/fonts/fira.css diff --git a/author/project/system/public/css/fonts/hack.css b/kodorvan/brainrot/system/public/css/fonts/hack.css similarity index 100% rename from author/project/system/public/css/fonts/hack.css rename to kodorvan/brainrot/system/public/css/fonts/hack.css diff --git a/author/project/system/public/fonts/commissioner.ttf b/kodorvan/brainrot/system/public/fonts/commissioner.ttf similarity index 100% rename from author/project/system/public/fonts/commissioner.ttf rename to kodorvan/brainrot/system/public/fonts/commissioner.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSans-Bold.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSans-Bold.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSans-Bold.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSans-Bold.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSans-BoldOblique.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSans-BoldOblique.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSans-BoldOblique.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSans-BoldOblique.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSans-ExtraLight.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSans-ExtraLight.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSans-ExtraLight.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSans-ExtraLight.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSans-Oblique.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSans-Oblique.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSans-Oblique.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSans-Oblique.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSans.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSans.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSans.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSans.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSansCondensed-Bold.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansCondensed-Bold.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSansCondensed-Bold.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansCondensed-Bold.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSansCondensed-BoldOblique.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansCondensed-BoldOblique.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSansCondensed-BoldOblique.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansCondensed-BoldOblique.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSansCondensed-Oblique.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansCondensed-Oblique.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSansCondensed-Oblique.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansCondensed-Oblique.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSansCondensed.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansCondensed.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSansCondensed.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansCondensed.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSansMono-Bold.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansMono-Bold.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSansMono-Bold.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansMono-Bold.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSansMono-BoldOblique.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansMono-BoldOblique.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSansMono-BoldOblique.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansMono-BoldOblique.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSansMono-Oblique.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansMono-Oblique.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSansMono-Oblique.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansMono-Oblique.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSansMono.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansMono.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSansMono.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSansMono.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSerif-Bold.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerif-Bold.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSerif-Bold.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerif-Bold.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSerif-BoldItalic.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerif-BoldItalic.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSerif-BoldItalic.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerif-BoldItalic.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSerif-Italic.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerif-Italic.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSerif-Italic.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerif-Italic.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSerif.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerif.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSerif.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerif.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSerifCondensed-Bold.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerifCondensed-Bold.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSerifCondensed-Bold.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerifCondensed-Bold.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSerifCondensed-BoldItalic.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerifCondensed-BoldItalic.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSerifCondensed-BoldItalic.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerifCondensed-BoldItalic.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSerifCondensed-Italic.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerifCondensed-Italic.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSerifCondensed-Italic.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerifCondensed-Italic.ttf diff --git a/author/project/system/public/fonts/dejavu/DejaVuLGCSerifCondensed.ttf b/kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerifCondensed.ttf similarity index 100% rename from author/project/system/public/fonts/dejavu/DejaVuLGCSerifCondensed.ttf rename to kodorvan/brainrot/system/public/fonts/dejavu/DejaVuLGCSerifCondensed.ttf diff --git a/author/project/system/public/fonts/fira/FiraMono-Bold.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraMono-Bold.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraMono-Bold.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraMono-Bold.woff diff --git a/author/project/system/public/fonts/fira/FiraMono-Bold.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraMono-Bold.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraMono-Bold.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraMono-Bold.woff2 diff --git a/author/project/system/public/fonts/fira/FiraMono-Medium.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraMono-Medium.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraMono-Medium.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraMono-Medium.woff diff --git a/author/project/system/public/fonts/fira/FiraMono-Medium.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraMono-Medium.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraMono-Medium.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraMono-Medium.woff2 diff --git a/author/project/system/public/fonts/fira/FiraMono-Regular.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraMono-Regular.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraMono-Regular.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraMono-Regular.woff diff --git a/author/project/system/public/fonts/fira/FiraMono-Regular.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraMono-Regular.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraMono-Regular.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraMono-Regular.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-Bold.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Bold.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Bold.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Bold.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-Bold.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Bold.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Bold.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Bold.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-BoldItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-BoldItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-BoldItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-BoldItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-BoldItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-BoldItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-BoldItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-BoldItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-Book.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Book.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Book.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Book.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-Book.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Book.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Book.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Book.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-BookItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-BookItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-BookItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-BookItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-BookItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-BookItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-BookItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-BookItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-Eight.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Eight.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Eight.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Eight.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-Eight.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Eight.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Eight.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Eight.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-EightItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-EightItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-EightItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-EightItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-EightItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-EightItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-EightItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-EightItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-ExtraBold.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraBold.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-ExtraBold.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraBold.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-ExtraBold.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraBold.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-ExtraBold.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraBold.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-ExtraBoldItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraBoldItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-ExtraBoldItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraBoldItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-ExtraBoldItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraBoldItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-ExtraBoldItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraBoldItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-ExtraLight.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraLight.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-ExtraLight.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraLight.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-ExtraLight.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraLight.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-ExtraLight.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraLight.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-ExtraLightItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraLightItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-ExtraLightItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraLightItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-ExtraLightItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraLightItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-ExtraLightItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-ExtraLightItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-Four.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Four.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Four.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Four.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-Four.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Four.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Four.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Four.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-FourItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-FourItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-FourItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-FourItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-FourItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-FourItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-FourItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-FourItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-Hair.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Hair.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Hair.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Hair.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-Hair.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Hair.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Hair.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Hair.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-HairItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-HairItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-HairItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-HairItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-HairItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-HairItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-HairItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-HairItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-Heavy.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Heavy.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Heavy.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Heavy.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-Heavy.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Heavy.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Heavy.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Heavy.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-HeavyItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-HeavyItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-HeavyItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-HeavyItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-HeavyItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-HeavyItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-HeavyItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-HeavyItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-Italic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Italic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Italic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Italic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-Italic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Italic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Italic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Italic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-Light.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Light.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Light.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Light.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-Light.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Light.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Light.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Light.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-LightItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-LightItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-LightItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-LightItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-LightItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-LightItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-LightItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-LightItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-Medium.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Medium.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Medium.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Medium.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-Medium.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Medium.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Medium.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Medium.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-MediumItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-MediumItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-MediumItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-MediumItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-MediumItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-MediumItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-MediumItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-MediumItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-Regular.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Regular.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Regular.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Regular.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-Regular.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Regular.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Regular.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Regular.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-SemiBold.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-SemiBold.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-SemiBold.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-SemiBold.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-SemiBold.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-SemiBold.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-SemiBold.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-SemiBold.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-SemiBoldItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-SemiBoldItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-SemiBoldItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-SemiBoldItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-SemiBoldItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-SemiBoldItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-SemiBoldItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-SemiBoldItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-Thin.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Thin.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Thin.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Thin.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-Thin.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Thin.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Thin.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Thin.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-ThinItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-ThinItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-ThinItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-ThinItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-ThinItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-ThinItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-ThinItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-ThinItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-Two.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Two.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Two.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Two.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-Two.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Two.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Two.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Two.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-TwoItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-TwoItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-TwoItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-TwoItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-TwoItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-TwoItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-TwoItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-TwoItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-Ultra.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Ultra.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Ultra.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Ultra.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-Ultra.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-Ultra.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-Ultra.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-Ultra.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-UltraItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-UltraItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-UltraItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-UltraItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-UltraItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-UltraItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-UltraItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-UltraItalic.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-UltraLight.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-UltraLight.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-UltraLight.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-UltraLight.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-UltraLight.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-UltraLight.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-UltraLight.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-UltraLight.woff2 diff --git a/author/project/system/public/fonts/fira/FiraSans-UltraLightItalic.woff b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-UltraLightItalic.woff similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-UltraLightItalic.woff rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-UltraLightItalic.woff diff --git a/author/project/system/public/fonts/fira/FiraSans-UltraLightItalic.woff2 b/kodorvan/brainrot/system/public/fonts/fira/FiraSans-UltraLightItalic.woff2 similarity index 100% rename from author/project/system/public/fonts/fira/FiraSans-UltraLightItalic.woff2 rename to kodorvan/brainrot/system/public/fonts/fira/FiraSans-UltraLightItalic.woff2 diff --git a/author/project/system/public/fonts/hack/hack-bold-subset.woff b/kodorvan/brainrot/system/public/fonts/hack/hack-bold-subset.woff similarity index 100% rename from author/project/system/public/fonts/hack/hack-bold-subset.woff rename to kodorvan/brainrot/system/public/fonts/hack/hack-bold-subset.woff diff --git a/author/project/system/public/fonts/hack/hack-bold-subset.woff2 b/kodorvan/brainrot/system/public/fonts/hack/hack-bold-subset.woff2 similarity index 100% rename from author/project/system/public/fonts/hack/hack-bold-subset.woff2 rename to kodorvan/brainrot/system/public/fonts/hack/hack-bold-subset.woff2 diff --git a/author/project/system/public/fonts/hack/hack-bold.woff b/kodorvan/brainrot/system/public/fonts/hack/hack-bold.woff similarity index 100% rename from author/project/system/public/fonts/hack/hack-bold.woff rename to kodorvan/brainrot/system/public/fonts/hack/hack-bold.woff diff --git a/author/project/system/public/fonts/hack/hack-bold.woff2 b/kodorvan/brainrot/system/public/fonts/hack/hack-bold.woff2 similarity index 100% rename from author/project/system/public/fonts/hack/hack-bold.woff2 rename to kodorvan/brainrot/system/public/fonts/hack/hack-bold.woff2 diff --git a/author/project/system/public/fonts/hack/hack-bolditalic-subset.woff b/kodorvan/brainrot/system/public/fonts/hack/hack-bolditalic-subset.woff similarity index 100% rename from author/project/system/public/fonts/hack/hack-bolditalic-subset.woff rename to kodorvan/brainrot/system/public/fonts/hack/hack-bolditalic-subset.woff diff --git a/author/project/system/public/fonts/hack/hack-bolditalic-subset.woff2 b/kodorvan/brainrot/system/public/fonts/hack/hack-bolditalic-subset.woff2 similarity index 100% rename from author/project/system/public/fonts/hack/hack-bolditalic-subset.woff2 rename to kodorvan/brainrot/system/public/fonts/hack/hack-bolditalic-subset.woff2 diff --git a/author/project/system/public/fonts/hack/hack-bolditalic.woff b/kodorvan/brainrot/system/public/fonts/hack/hack-bolditalic.woff similarity index 100% rename from author/project/system/public/fonts/hack/hack-bolditalic.woff rename to kodorvan/brainrot/system/public/fonts/hack/hack-bolditalic.woff diff --git a/author/project/system/public/fonts/hack/hack-bolditalic.woff2 b/kodorvan/brainrot/system/public/fonts/hack/hack-bolditalic.woff2 similarity index 100% rename from author/project/system/public/fonts/hack/hack-bolditalic.woff2 rename to kodorvan/brainrot/system/public/fonts/hack/hack-bolditalic.woff2 diff --git a/author/project/system/public/fonts/hack/hack-italic-subset.woff b/kodorvan/brainrot/system/public/fonts/hack/hack-italic-subset.woff similarity index 100% rename from author/project/system/public/fonts/hack/hack-italic-subset.woff rename to kodorvan/brainrot/system/public/fonts/hack/hack-italic-subset.woff diff --git a/author/project/system/public/fonts/hack/hack-italic-subset.woff2 b/kodorvan/brainrot/system/public/fonts/hack/hack-italic-subset.woff2 similarity index 100% rename from author/project/system/public/fonts/hack/hack-italic-subset.woff2 rename to kodorvan/brainrot/system/public/fonts/hack/hack-italic-subset.woff2 diff --git a/author/project/system/public/fonts/hack/hack-italic.woff b/kodorvan/brainrot/system/public/fonts/hack/hack-italic.woff similarity index 100% rename from author/project/system/public/fonts/hack/hack-italic.woff rename to kodorvan/brainrot/system/public/fonts/hack/hack-italic.woff diff --git a/author/project/system/public/fonts/hack/hack-italic.woff2 b/kodorvan/brainrot/system/public/fonts/hack/hack-italic.woff2 similarity index 100% rename from author/project/system/public/fonts/hack/hack-italic.woff2 rename to kodorvan/brainrot/system/public/fonts/hack/hack-italic.woff2 diff --git a/author/project/system/public/fonts/hack/hack-regular-subset.woff b/kodorvan/brainrot/system/public/fonts/hack/hack-regular-subset.woff similarity index 100% rename from author/project/system/public/fonts/hack/hack-regular-subset.woff rename to kodorvan/brainrot/system/public/fonts/hack/hack-regular-subset.woff diff --git a/author/project/system/public/fonts/hack/hack-regular-subset.woff2 b/kodorvan/brainrot/system/public/fonts/hack/hack-regular-subset.woff2 similarity index 100% rename from author/project/system/public/fonts/hack/hack-regular-subset.woff2 rename to kodorvan/brainrot/system/public/fonts/hack/hack-regular-subset.woff2 diff --git a/author/project/system/public/fonts/hack/hack-regular.woff b/kodorvan/brainrot/system/public/fonts/hack/hack-regular.woff similarity index 100% rename from author/project/system/public/fonts/hack/hack-regular.woff rename to kodorvan/brainrot/system/public/fonts/hack/hack-regular.woff diff --git a/author/project/system/public/fonts/hack/hack-regular.woff2 b/kodorvan/brainrot/system/public/fonts/hack/hack-regular.woff2 similarity index 100% rename from author/project/system/public/fonts/hack/hack-regular.woff2 rename to kodorvan/brainrot/system/public/fonts/hack/hack-regular.woff2 diff --git a/author/project/system/public/index.php b/kodorvan/brainrot/system/public/index.php similarity index 100% rename from author/project/system/public/index.php rename to kodorvan/brainrot/system/public/index.php diff --git a/kodorvan/brainrot/system/public/js/modules/damper.mjs b/kodorvan/brainrot/system/public/js/modules/damper.mjs new file mode 120000 index 0000000..2b4d1e5 --- /dev/null +++ b/kodorvan/brainrot/system/public/js/modules/damper.mjs @@ -0,0 +1 @@ +../../../../../../damper.mjs/damper.mjs \ No newline at end of file diff --git a/kodorvan/brainrot/system/public/telegram.php b/kodorvan/brainrot/system/public/telegram.php new file mode 100644 index 0000000..edb4bfd --- /dev/null +++ b/kodorvan/brainrot/system/public/telegram.php @@ -0,0 +1,107 @@ +setParseMode(config::PARSE_MODE_MARKDOWN); +$config->useReactFileSystem(true); + +// Initializing the robot +$robot = new Zanzara(TELEGRAM_KEY, $config); + +// Initializing the updates listener +$robot->onUpdate(function (Context $context): void {}); + +// Initializing the robot middlewares +$robot->middleware([middlewares::class, 'account']); +$robot->middleware([middlewares::class, 'language']); +$robot->middleware([middlewares::class, 'localization']); + +// Initializing the robot commands handlers +$robot->onCommand('start', [commands::class, 'menu']); +$robot->onCommand('menu', [commands::class, 'menu']); +$robot->onCommand('account', [commands::class, 'account']); +$robot->onCommand('language', [commands::class, 'language'])->middleware([middlewares::class, 'settings']); +$robot->onCommand('repository', [commands::class, 'repository']); +/* $robot->onCommand('projects', [commands::class, 'projects']); */ +$robot->onCommand('author', [commands::class, 'author']); +$robot->onCommand('society', [commands::class, 'society']); +/* $robot->onCommand('system_settings', [commands::class, 'system_settings'])->middleware([middlewares::class, 'system_settings']); */ + +// Initializing the robot buttons handlers +/* $robot->onCbQueryData(['account_localizations'], [account::class, 'localizations']); +$robot->onCbQueryData(['account_localization_create_start'], [process_account_localization_create::class, 'start']); */ + + +// Initializing the robot settings language buttons handlers +foreach (language::cases() as $language) { + // Iterating over languages + + // Initializing language buttons + $robot->onCbQueryData(['settings_language_' . $language->name], fn(context $context) => settings::language($context, $language)); +}; + +// Starting chat-robot +$robot->run(); diff --git a/author/project/system/public/themes/default/css/aside.css b/kodorvan/brainrot/system/public/themes/default/css/aside.css similarity index 100% rename from author/project/system/public/themes/default/css/aside.css rename to kodorvan/brainrot/system/public/themes/default/css/aside.css diff --git a/author/project/system/public/themes/default/css/colorscheme.css b/kodorvan/brainrot/system/public/themes/default/css/colorscheme.css similarity index 100% rename from author/project/system/public/themes/default/css/colorscheme.css rename to kodorvan/brainrot/system/public/themes/default/css/colorscheme.css diff --git a/author/project/system/public/themes/default/css/fonts.css b/kodorvan/brainrot/system/public/themes/default/css/fonts.css similarity index 100% rename from author/project/system/public/themes/default/css/fonts.css rename to kodorvan/brainrot/system/public/themes/default/css/fonts.css diff --git a/author/project/system/public/themes/default/css/footer.css b/kodorvan/brainrot/system/public/themes/default/css/footer.css similarity index 100% rename from author/project/system/public/themes/default/css/footer.css rename to kodorvan/brainrot/system/public/themes/default/css/footer.css diff --git a/author/project/system/public/themes/default/css/header.css b/kodorvan/brainrot/system/public/themes/default/css/header.css similarity index 100% rename from author/project/system/public/themes/default/css/header.css rename to kodorvan/brainrot/system/public/themes/default/css/header.css diff --git a/author/project/system/public/themes/default/css/main.css b/kodorvan/brainrot/system/public/themes/default/css/main.css similarity index 100% rename from author/project/system/public/themes/default/css/main.css rename to kodorvan/brainrot/system/public/themes/default/css/main.css diff --git a/author/project/system/public/themes/default/css/system.css b/kodorvan/brainrot/system/public/themes/default/css/system.css similarity index 100% rename from author/project/system/public/themes/default/css/system.css rename to kodorvan/brainrot/system/public/themes/default/css/system.css diff --git a/author/project/system/settings/.gitignore b/kodorvan/brainrot/system/settings/.gitignore similarity index 100% rename from author/project/system/settings/.gitignore rename to kodorvan/brainrot/system/settings/.gitignore diff --git a/author/project/system/settings/system.php.sample b/kodorvan/brainrot/system/settings/system.php.sample similarity index 100% rename from author/project/system/settings/system.php.sample rename to kodorvan/brainrot/system/settings/system.php.sample diff --git a/kodorvan/brainrot/system/settings/telegram.php.sample b/kodorvan/brainrot/system/settings/telegram.php.sample new file mode 100644 index 0000000..ac90fc3 --- /dev/null +++ b/kodorvan/brainrot/system/settings/telegram.php.sample @@ -0,0 +1,4 @@ + - * @author kodorvan */ final class templater extends controller implements array_access { diff --git a/author/project/system/views/themes/default/aside.html b/kodorvan/brainrot/system/views/themes/default/aside.html similarity index 100% rename from author/project/system/views/themes/default/aside.html rename to kodorvan/brainrot/system/views/themes/default/aside.html diff --git a/author/project/system/views/themes/default/core.html b/kodorvan/brainrot/system/views/themes/default/core.html similarity index 100% rename from author/project/system/views/themes/default/core.html rename to kodorvan/brainrot/system/views/themes/default/core.html diff --git a/author/project/system/views/themes/default/footer.html b/kodorvan/brainrot/system/views/themes/default/footer.html similarity index 100% rename from author/project/system/views/themes/default/footer.html rename to kodorvan/brainrot/system/views/themes/default/footer.html diff --git a/author/project/system/views/themes/default/head.html b/kodorvan/brainrot/system/views/themes/default/head.html similarity index 100% rename from author/project/system/views/themes/default/head.html rename to kodorvan/brainrot/system/views/themes/default/head.html diff --git a/author/project/system/views/themes/default/header.html b/kodorvan/brainrot/system/views/themes/default/header.html similarity index 100% rename from author/project/system/views/themes/default/header.html rename to kodorvan/brainrot/system/views/themes/default/header.html diff --git a/author/project/system/views/themes/default/index.html b/kodorvan/brainrot/system/views/themes/default/index.html similarity index 100% rename from author/project/system/views/themes/default/index.html rename to kodorvan/brainrot/system/views/themes/default/index.html diff --git a/author/project/system/views/themes/default/js.html b/kodorvan/brainrot/system/views/themes/default/js.html similarity index 100% rename from author/project/system/views/themes/default/js.html rename to kodorvan/brainrot/system/views/themes/default/js.html