diff --git a/app/Http/Controllers/TelegramController.php b/app/Http/Controllers/TelegramController.php index 16260b9..032d4f6 100755 --- a/app/Http/Controllers/TelegramController.php +++ b/app/Http/Controllers/TelegramController.php @@ -46,6 +46,7 @@ public function processWebhook(TelegramService $telegramService): void if (!$telegramMessage) { Log::warning('Invalid Telegram message', ['payload' => $payload]); + return; } diff --git a/app/Jobs/GenerateCalendarJob.php b/app/Jobs/GenerateCalendarJob.php index ea73f04..1350ead 100755 --- a/app/Jobs/GenerateCalendarJob.php +++ b/app/Jobs/GenerateCalendarJob.php @@ -205,7 +205,7 @@ private function generateOpenAIResponse(): CreateResponse */ private function generateMistralResponse(): stdClass { - $response = Http::mistral()->timeout(10)->post('/chat/completions', [ + $response = Http::mistral()->timeout(Config::integer('mistral.request_timeout'))->post('/chat/completions', [ 'model' => Config::string('mistral.model'), 'messages' => $this->aiMessages, 'max_tokens' => 3700, diff --git a/composer.json b/composer.json index 245e85b..f767e4a 100755 --- a/composer.json +++ b/composer.json @@ -21,12 +21,12 @@ "lemonsqueezy/laravel": "^1.8.1", "masbug/flysystem-google-drive-ext": "^2.4.1", "openai-php/laravel": "^0.9.1", - "spatie/icalendar-generator": "^2.9.0", + "spatie/icalendar-generator": "^2.9.1", "spatie/laravel-backup": "^8.8.2", "spatie/laravel-data": "^4.13.0", "spatie/laravel-ray": "^1.39.0", "symfony/http-client": "^7.2.3", - "tightenco/ziggy": "^2.5.0" + "tightenco/ziggy": "^2.5.1" }, "require-dev": { "driftingly/rector-laravel": "^1.2.6", @@ -43,7 +43,7 @@ "pestphp/pest-plugin-laravel": "^2.4", "rector/rector": "^1.2.10", "spatie/laravel-ignition": "^2.9.0", - "spatie/laravel-sitemap": "^7.3.3" + "spatie/laravel-sitemap": "^7.3.4" }, "autoload": { "psr-4": { diff --git a/composer.lock b/composer.lock index d158613..c1e3659 100755 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "90900401b9a90244ae77e1e283b6f579", + "content-hash": "69f3d96b048e8decc092a98452c6c26a", "packages": [ { "name": "amphp/amp", @@ -1917,16 +1917,16 @@ }, { "name": "google/apiclient-services", - "version": "v0.392.0", + "version": "v0.393.0", "source": { "type": "git", "url": "https://github.com/googleapis/google-api-php-client-services.git", - "reference": "a74c2790865bd1f06c0a49460ef1c0edb0be0e7e" + "reference": "ed24c09584df8ef0cdcfb9d4305abf66fc17e609" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/googleapis/google-api-php-client-services/zipball/a74c2790865bd1f06c0a49460ef1c0edb0be0e7e", - "reference": "a74c2790865bd1f06c0a49460ef1c0edb0be0e7e", + "url": "https://api.github.com/repos/googleapis/google-api-php-client-services/zipball/ed24c09584df8ef0cdcfb9d4305abf66fc17e609", + "reference": "ed24c09584df8ef0cdcfb9d4305abf66fc17e609", "shasum": "" }, "require": { @@ -1955,9 +1955,9 @@ ], "support": { "issues": "https://github.com/googleapis/google-api-php-client-services/issues", - "source": "https://github.com/googleapis/google-api-php-client-services/tree/v0.392.0" + "source": "https://github.com/googleapis/google-api-php-client-services/tree/v0.393.0" }, - "time": "2025-01-27T01:10:20+00:00" + "time": "2025-02-03T00:54:21+00:00" }, { "name": "google/auth", @@ -2409,16 +2409,16 @@ }, { "name": "guzzlehttp/uri-template", - "version": "v1.0.3", + "version": "v1.0.4", "source": { "type": "git", "url": "https://github.com/guzzle/uri-template.git", - "reference": "ecea8feef63bd4fef1f037ecb288386999ecc11c" + "reference": "30e286560c137526eccd4ce21b2de477ab0676d2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/uri-template/zipball/ecea8feef63bd4fef1f037ecb288386999ecc11c", - "reference": "ecea8feef63bd4fef1f037ecb288386999ecc11c", + "url": "https://api.github.com/repos/guzzle/uri-template/zipball/30e286560c137526eccd4ce21b2de477ab0676d2", + "reference": "30e286560c137526eccd4ce21b2de477ab0676d2", "shasum": "" }, "require": { @@ -2475,7 +2475,7 @@ ], "support": { "issues": "https://github.com/guzzle/uri-template/issues", - "source": "https://github.com/guzzle/uri-template/tree/v1.0.3" + "source": "https://github.com/guzzle/uri-template/tree/v1.0.4" }, "funding": [ { @@ -2491,7 +2491,7 @@ "type": "tidelift" } ], - "time": "2023-12-03T19:50:20+00:00" + "time": "2025-02-03T10:55:03+00:00" }, { "name": "inertiajs/inertia-laravel", @@ -7661,16 +7661,16 @@ }, { "name": "spatie/icalendar-generator", - "version": "2.9.0", + "version": "2.9.1", "source": { "type": "git", "url": "https://github.com/spatie/icalendar-generator.git", - "reference": "9df8161a6b771d232890826011356734e46ed57c" + "reference": "21b8d259156368812a6d55096499f289b265be4e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/icalendar-generator/zipball/9df8161a6b771d232890826011356734e46ed57c", - "reference": "9df8161a6b771d232890826011356734e46ed57c", + "url": "https://api.github.com/repos/spatie/icalendar-generator/zipball/21b8d259156368812a6d55096499f289b265be4e", + "reference": "21b8d259156368812a6d55096499f289b265be4e", "shasum": "" }, "require": { @@ -7683,8 +7683,7 @@ "larapack/dd": "^1.1", "nesbot/carbon": "^3.5", "pestphp/pest": "^2.34", - "spatie/pest-plugin-snapshots": "^2.1", - "vimeo/psalm": "^5.24" + "spatie/pest-plugin-snapshots": "^2.1" }, "type": "library", "autoload": { @@ -7715,9 +7714,9 @@ ], "support": { "issues": "https://github.com/spatie/icalendar-generator/issues", - "source": "https://github.com/spatie/icalendar-generator/tree/2.9.0" + "source": "https://github.com/spatie/icalendar-generator/tree/2.9.1" }, - "time": "2024-12-02T08:41:57+00:00" + "time": "2025-01-31T13:50:13+00:00" }, { "name": "spatie/laravel-backup", @@ -10946,16 +10945,16 @@ }, { "name": "tightenco/ziggy", - "version": "v2.5.0", + "version": "v2.5.1", "source": { "type": "git", "url": "https://github.com/tighten/ziggy.git", - "reference": "2b574ba281546884b7bdde6eefa451ba7e0b52f7" + "reference": "40df446f6053787edb245381c3b3d80b031b5fc0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/tighten/ziggy/zipball/2b574ba281546884b7bdde6eefa451ba7e0b52f7", - "reference": "2b574ba281546884b7bdde6eefa451ba7e0b52f7", + "url": "https://api.github.com/repos/tighten/ziggy/zipball/40df446f6053787edb245381c3b3d80b031b5fc0", + "reference": "40df446f6053787edb245381c3b3d80b031b5fc0", "shasum": "" }, "require": { @@ -11010,9 +11009,9 @@ ], "support": { "issues": "https://github.com/tighten/ziggy/issues", - "source": "https://github.com/tighten/ziggy/tree/v2.5.0" + "source": "https://github.com/tighten/ziggy/tree/v2.5.1" }, - "time": "2025-01-23T00:32:18+00:00" + "time": "2025-01-31T19:23:01+00:00" }, { "name": "tijsverkoyen/css-to-inline-styles", @@ -16111,16 +16110,16 @@ }, { "name": "spatie/laravel-sitemap", - "version": "7.3.3", + "version": "7.3.4", "source": { "type": "git", "url": "https://github.com/spatie/laravel-sitemap.git", - "reference": "9423e3bb82d9e83fa8969a2a30dcea309d802e7e" + "reference": "5606b9e7b1cb2785218999a6f2ee11e0dbdcfb56" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/laravel-sitemap/zipball/9423e3bb82d9e83fa8969a2a30dcea309d802e7e", - "reference": "9423e3bb82d9e83fa8969a2a30dcea309d802e7e", + "url": "https://api.github.com/repos/spatie/laravel-sitemap/zipball/5606b9e7b1cb2785218999a6f2ee11e0dbdcfb56", + "reference": "5606b9e7b1cb2785218999a6f2ee11e0dbdcfb56", "shasum": "" }, "require": { @@ -16172,7 +16171,7 @@ "spatie" ], "support": { - "source": "https://github.com/spatie/laravel-sitemap/tree/7.3.3" + "source": "https://github.com/spatie/laravel-sitemap/tree/7.3.4" }, "funding": [ { @@ -16180,20 +16179,20 @@ "type": "custom" } ], - "time": "2025-01-27T09:44:53+00:00" + "time": "2025-01-31T08:53:45+00:00" }, { "name": "spatie/robots-txt", - "version": "2.3.0", + "version": "2.3.1", "source": { "type": "git", "url": "https://github.com/spatie/robots-txt.git", - "reference": "acc7f4438813989d0427624f7901232084916170" + "reference": "58ed7b61c2a59e72f57b46e4d025967dd5f16000" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/robots-txt/zipball/acc7f4438813989d0427624f7901232084916170", - "reference": "acc7f4438813989d0427624f7901232084916170", + "url": "https://api.github.com/repos/spatie/robots-txt/zipball/58ed7b61c2a59e72f57b46e4d025967dd5f16000", + "reference": "58ed7b61c2a59e72f57b46e4d025967dd5f16000", "shasum": "" }, "require": { @@ -16228,7 +16227,7 @@ ], "support": { "issues": "https://github.com/spatie/robots-txt/issues", - "source": "https://github.com/spatie/robots-txt/tree/2.3.0" + "source": "https://github.com/spatie/robots-txt/tree/2.3.1" }, "funding": [ { @@ -16240,7 +16239,7 @@ "type": "github" } ], - "time": "2025-01-27T10:15:34+00:00" + "time": "2025-01-31T09:33:25+00:00" }, { "name": "squizlabs/php_codesniffer", diff --git a/config/openai.php b/config/openai.php index cee6101..92f31a8 100755 --- a/config/openai.php +++ b/config/openai.php @@ -4,7 +4,7 @@ 'api_key' => env('OPENAI_API_KEY'), 'organization' => env('OPENAI_ORGANIZATION'), - 'model' => 'o3-mini', + 'model' => 'gpt-4o', 'system_prompt' => env('OPENAI_SYSTEM_PROMPT') ? base64_decode(env('OPENAI_SYSTEM_PROMPT')) : '', diff --git a/package-lock.json b/package-lock.json index 2adc809..af88f9e 100755 --- a/package-lock.json +++ b/package-lock.json @@ -9,13 +9,13 @@ "@inertiajs/server": "^0.1.0", "@vueuse/core": "^12.5.0", "laravel-vue-i18n": "^2.7.8", - "swiper": "^11.2.1", + "swiper": "^11.2.2", "vue": "^3.5.13" }, "devDependencies": { "@inertiajs/vue3": "^2.0.3", "@tailwindcss/forms": "^0.5.10", - "@tailwindcss/postcss": "^4.0.1", + "@tailwindcss/postcss": "^4.0.3", "@vitejs/plugin-vue": "^5.2.1", "@vue/server-renderer": "^3.5.13", "axios": "^1.7.9", @@ -28,7 +28,7 @@ "prettier-plugin-merge": "^0.7.2", "prettier-plugin-tailwindcss": "^0.6.11", "pusher-js": "^8.4.0", - "tailwindcss": "^4.0.1", + "tailwindcss": "^4.0.3", "typescript": "5.7.3", "vite": "^6.0", "vue": "^3.5.13", @@ -1187,15 +1187,15 @@ } }, "node_modules/@tailwindcss/node": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/node/-/node-4.0.1.tgz", - "integrity": "sha512-lc+ly6PKHqgCVl7eO8D2JlV96Lks5bmL6pdtM6UasyUHLU2zmrOqU6jfgln120IVnCh3VC8GG/ca24xVTtSokw==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/node/-/node-4.0.3.tgz", + "integrity": "sha512-QsVJokOl0pJ4AbJV33D2npvLcHGPWi5MOSZtrtE0GT3tSx+3D0JE2lokLA8yHS1x3oCY/3IyRyy7XX6tmzid7A==", "dev": true, "license": "MIT", "dependencies": { "enhanced-resolve": "^5.18.0", "jiti": "^2.4.2", - "tailwindcss": "4.0.1" + "tailwindcss": "4.0.3" } }, "node_modules/@tailwindcss/node/node_modules/jiti": { @@ -1209,32 +1209,32 @@ } }, "node_modules/@tailwindcss/oxide": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide/-/oxide-4.0.1.tgz", - "integrity": "sha512-3z1SpWoDeaA6K6jd92CRrGyDghOcRILEgyWVHRhaUm/tcpiazwJpU9BSG0xB7GGGnl9capojaC+zme/nKsZd/w==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide/-/oxide-4.0.3.tgz", + "integrity": "sha512-FFcp3VNvRjjmFA39ORM27g2mbflMQljhvM7gxBAujHxUy4LXlKa6yMF9wbHdTbPqTONiCyyOYxccvJyVyI/XBg==", "dev": true, "license": "MIT", "engines": { "node": ">= 10" }, "optionalDependencies": { - "@tailwindcss/oxide-android-arm64": "4.0.1", - "@tailwindcss/oxide-darwin-arm64": "4.0.1", - "@tailwindcss/oxide-darwin-x64": "4.0.1", - "@tailwindcss/oxide-freebsd-x64": "4.0.1", - "@tailwindcss/oxide-linux-arm-gnueabihf": "4.0.1", - "@tailwindcss/oxide-linux-arm64-gnu": "4.0.1", - "@tailwindcss/oxide-linux-arm64-musl": "4.0.1", - "@tailwindcss/oxide-linux-x64-gnu": "4.0.1", - "@tailwindcss/oxide-linux-x64-musl": "4.0.1", - "@tailwindcss/oxide-win32-arm64-msvc": "4.0.1", - "@tailwindcss/oxide-win32-x64-msvc": "4.0.1" + "@tailwindcss/oxide-android-arm64": "4.0.3", + "@tailwindcss/oxide-darwin-arm64": "4.0.3", + "@tailwindcss/oxide-darwin-x64": "4.0.3", + "@tailwindcss/oxide-freebsd-x64": "4.0.3", + "@tailwindcss/oxide-linux-arm-gnueabihf": "4.0.3", + "@tailwindcss/oxide-linux-arm64-gnu": "4.0.3", + "@tailwindcss/oxide-linux-arm64-musl": "4.0.3", + "@tailwindcss/oxide-linux-x64-gnu": "4.0.3", + "@tailwindcss/oxide-linux-x64-musl": "4.0.3", + "@tailwindcss/oxide-win32-arm64-msvc": "4.0.3", + "@tailwindcss/oxide-win32-x64-msvc": "4.0.3" } }, "node_modules/@tailwindcss/oxide-android-arm64": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-android-arm64/-/oxide-android-arm64-4.0.1.tgz", - "integrity": "sha512-eP/rI9WaAElpeiiHDqGtDqga9iDsOClXxIqdHayHsw93F24F03b60CwgGhrGF9Io/EuWIpz3TMRhPVOLhoXivw==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-android-arm64/-/oxide-android-arm64-4.0.3.tgz", + "integrity": "sha512-S8XOTQuMnpijZRlPm5HBzPJjZ28quB+40LSRHjRnQF6rRYKsvpr1qkY7dfwsetNdd+kMLOMDsvmuT8WnqqETvg==", "cpu": [ "arm64" ], @@ -1249,9 +1249,9 @@ } }, "node_modules/@tailwindcss/oxide-darwin-arm64": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-arm64/-/oxide-darwin-arm64-4.0.1.tgz", - "integrity": "sha512-jZVUo0kNd1IjxdCYwg4dwegDNsq7PoUx4LM814RmgY3gfJ63Y6GlpJXHOpd5FLv1igpeZox5LzRk2oz8MQoJwQ==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-arm64/-/oxide-darwin-arm64-4.0.3.tgz", + "integrity": "sha512-smrY2DpzhXvgDhZtQlYAl8+vxJ04lv2/64C1eiRxvsRT2nkw/q+zA1/eAYKvUHat6cIuwqDku3QucmrUT6pCeg==", "cpu": [ "arm64" ], @@ -1266,9 +1266,9 @@ } }, "node_modules/@tailwindcss/oxide-darwin-x64": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-x64/-/oxide-darwin-x64-4.0.1.tgz", - "integrity": "sha512-E31wHiIf4LB0aKRohrS4U6XfFSACCL9ifUFfPQ16FhcBIL4wU5rcBidvWvT9TQFGPkpE69n5dyXUcqiMrnF/Ig==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-x64/-/oxide-darwin-x64-4.0.3.tgz", + "integrity": "sha512-NTz8x/LcGUjpZAWUxz0ZuzHao90Wj9spoQgomwB+/hgceh5gcJDfvaBYqxLFpKzVglpnbDSq1Fg0p0zI4oa5Pg==", "cpu": [ "x64" ], @@ -1283,9 +1283,9 @@ } }, "node_modules/@tailwindcss/oxide-freebsd-x64": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-freebsd-x64/-/oxide-freebsd-x64-4.0.1.tgz", - "integrity": "sha512-8/3ZKLMYqgAsBzTeczOKWtT4geF02g9S7cntY5gvqQZ4E0ImX724cHcZJi9k6fkE6aLbvwxxHxaShFvRxblwKQ==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-freebsd-x64/-/oxide-freebsd-x64-4.0.3.tgz", + "integrity": "sha512-yQc9Q0JCOp3kkAV8gKgDctXO60IkQhHpqGB+KgOccDtD5UmN6Q5+gd+lcsDyQ7N8dRuK1fAud51xQpZJgKfm7g==", "cpu": [ "x64" ], @@ -1300,9 +1300,9 @@ } }, "node_modules/@tailwindcss/oxide-linux-arm-gnueabihf": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm-gnueabihf/-/oxide-linux-arm-gnueabihf-4.0.1.tgz", - "integrity": "sha512-EYjbh225klQfWzy6LeIAfdjHCK+p71yLV/GjdPNW47Bfkkq05fTzIhHhCgshUvNp78EIA33iQU+ktWpW06NgHw==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm-gnueabihf/-/oxide-linux-arm-gnueabihf-4.0.3.tgz", + "integrity": "sha512-e1ivVMLSnxTOU1O3npnxN16FEyWM/g3SuH2pP6udxXwa0/SnSAijRwcAYRpqIlhVKujr158S8UeHxQjC4fGl4w==", "cpu": [ "arm" ], @@ -1317,9 +1317,9 @@ } }, "node_modules/@tailwindcss/oxide-linux-arm64-gnu": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-gnu/-/oxide-linux-arm64-gnu-4.0.1.tgz", - "integrity": "sha512-PrX2SwIqWNP5cYeSyQfrhbk4ffOM338T6CrEwIAGvLPoUZiklt19yknlsBme6bReSw7TSAMy+8KFdLLi5fcWNQ==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-gnu/-/oxide-linux-arm64-gnu-4.0.3.tgz", + "integrity": "sha512-PLrToqQqX6sdJ9DmMi8IxZWWrfjc9pdi9AEEPTrtMts3Jm9HBi1WqEeF1VwZZ2aW9TXloE5OwA35zuuq1Bhb/Q==", "cpu": [ "arm64" ], @@ -1334,9 +1334,9 @@ } }, "node_modules/@tailwindcss/oxide-linux-arm64-musl": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-musl/-/oxide-linux-arm64-musl-4.0.1.tgz", - "integrity": "sha512-iuoFGhKDojtfloi5uj6MIk4kxEOGcsAk/kPbZItF9Dp7TnzVhxo2U/718tXhxGrg6jSL3ST3cQHIjA6yw3OeXw==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-musl/-/oxide-linux-arm64-musl-4.0.3.tgz", + "integrity": "sha512-YlzRxx7N1ampfgSKzEDw0iwDkJXUInR4cgNEqmR4TzHkU2Vhg59CGPJrTI7dxOBofD8+O35R13Nk9Ytyv0JUFg==", "cpu": [ "arm64" ], @@ -1351,9 +1351,9 @@ } }, "node_modules/@tailwindcss/oxide-linux-x64-gnu": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-gnu/-/oxide-linux-x64-gnu-4.0.1.tgz", - "integrity": "sha512-pNUrGQYyE8RK+N9yvkPmHnlKDfFbni9A3lsi37u4RoA/6Yn+zWVoegvAQMZu3w+jqnpb2A/bYJ+LumcclUZ3yg==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-gnu/-/oxide-linux-x64-gnu-4.0.3.tgz", + "integrity": "sha512-Xfc3z/li6XkuD7Hs+Uk6pjyCXnfnd9zuQTKOyDTZJ544xc2yoMKUkuDw6Et9wb31MzU2/c0CIUpTDa71lL9KHw==", "cpu": [ "x64" ], @@ -1368,9 +1368,9 @@ } }, "node_modules/@tailwindcss/oxide-linux-x64-musl": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-musl/-/oxide-linux-x64-musl-4.0.1.tgz", - "integrity": "sha512-xSGWaDcT6SJ75su9zWXj8GYb2jM/przXwZGH96RTS7HGDIoI1tvgpls88YajG5Sx7hXaqAWCufjw5L/dlu+lzg==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-musl/-/oxide-linux-x64-musl-4.0.3.tgz", + "integrity": "sha512-ugKVqKzwa/cjmqSQG17aS9DYrEcQ/a5NITcgmOr3JLW4Iz64C37eoDlkC8tIepD3S/Td/ywKAolTQ8fKbjEL4g==", "cpu": [ "x64" ], @@ -1385,9 +1385,9 @@ } }, "node_modules/@tailwindcss/oxide-win32-arm64-msvc": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-arm64-msvc/-/oxide-win32-arm64-msvc-4.0.1.tgz", - "integrity": "sha512-BUNL2isUZ2yWnbplPddggJpZxsqGHPZ1RJAYpu63W4znUnKCzI4m/jiy0WpyYqqOKL9jDM5q0QdsQ9mc3aw5YQ==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-arm64-msvc/-/oxide-win32-arm64-msvc-4.0.3.tgz", + "integrity": "sha512-qHPDMl+UUwsk1RMJMgAXvhraWqUUT+LR/tkXix5RA39UGxtTrHwsLIN1AhNxI5i2RFXAXfmFXDqZCdyQ4dWmAQ==", "cpu": [ "arm64" ], @@ -1402,9 +1402,9 @@ } }, "node_modules/@tailwindcss/oxide-win32-x64-msvc": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-x64-msvc/-/oxide-win32-x64-msvc-4.0.1.tgz", - "integrity": "sha512-ZtcVu+XXOddGsPlvO5nh2fnbKmwly2C07ZB1lcYCf/b8qIWF04QY9o6vy6/+6ioLRfbp3E7H/ipFio38DZX4oQ==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-x64-msvc/-/oxide-win32-x64-msvc-4.0.3.tgz", + "integrity": "sha512-+ujwN4phBGyOsPyLgGgeCyUm4Mul+gqWVCIGuSXWgrx9xVUnf6LVXrw0BDBc9Aq1S2qMyOTX4OkCGbZeoIo8Qw==", "cpu": [ "x64" ], @@ -1419,18 +1419,18 @@ } }, "node_modules/@tailwindcss/postcss": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@tailwindcss/postcss/-/postcss-4.0.1.tgz", - "integrity": "sha512-fZHL49vCDauQymdm2U1jehuUeX8msYVDKB/2v+jWhTQleH3QE8J1dJ2dnL5tqRvB0udjBP4kwUC1ZIVIdv66YA==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@tailwindcss/postcss/-/postcss-4.0.3.tgz", + "integrity": "sha512-qUyxuhuI2eTgRJ+qfCQRAr69Cw7BdSz+PoNFUNoRuhPjikNC8+sxK+Mi/chaXAXewjv/zbf6if6z6ItVLh+e9Q==", "dev": true, "license": "MIT", "dependencies": { "@alloc/quick-lru": "^5.2.0", - "@tailwindcss/node": "^4.0.1", - "@tailwindcss/oxide": "^4.0.1", + "@tailwindcss/node": "^4.0.3", + "@tailwindcss/oxide": "^4.0.3", "lightningcss": "^1.29.1", "postcss": "^8.4.41", - "tailwindcss": "4.0.1" + "tailwindcss": "4.0.3" } }, "node_modules/@types/estree": { @@ -5435,9 +5435,9 @@ } }, "node_modules/swiper": { - "version": "11.2.1", - "resolved": "https://registry.npmjs.org/swiper/-/swiper-11.2.1.tgz", - "integrity": "sha512-62G69+iQRIfUqTmJkWpZDcX891Ra8O9050ckt1/JI2H+0483g+gq0m7gINecDqMtDh2zt5dK+uzBRxGhGOOvQA==", + "version": "11.2.2", + "resolved": "https://registry.npmjs.org/swiper/-/swiper-11.2.2.tgz", + "integrity": "sha512-FmAN6zACpVUbd/1prO9xQ9gKo9cc6RE2UKU/z4oXtS8fNyX4sdOW/HHT/e444WucLJs0jeMId6WjdWM2Lrs8zA==", "funding": [ { "type": "patreon", @@ -5454,9 +5454,9 @@ } }, "node_modules/tailwindcss": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-4.0.1.tgz", - "integrity": "sha512-UK5Biiit/e+r3i0O223bisoS5+y7ZT1PM8Ojn0MxRHzXN1VPZ2KY6Lo6fhu1dOfCfyUAlK7Lt6wSxowRabATBw==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-4.0.3.tgz", + "integrity": "sha512-ImmZF0Lon5RrQpsEAKGxRvHwCvMgSC4XVlFRqmbzTEDb/3wvin9zfEZrMwgsa3yqBbPqahYcVI6lulM2S7IZAA==", "dev": true, "license": "MIT" }, diff --git a/package.json b/package.json index 6193cc3..8f2ed48 100755 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ "devDependencies": { "@inertiajs/vue3": "^2.0.3", "@tailwindcss/forms": "^0.5.10", - "@tailwindcss/postcss": "^4.0.1", + "@tailwindcss/postcss": "^4.0.3", "@vitejs/plugin-vue": "^5.2.1", "@vue/server-renderer": "^3.5.13", "axios": "^1.7.9", @@ -21,7 +21,7 @@ "prettier-plugin-merge": "^0.7.2", "prettier-plugin-tailwindcss": "^0.6.11", "pusher-js": "^8.4.0", - "tailwindcss": "^4.0.1", + "tailwindcss": "^4.0.3", "typescript": "5.7.3", "vite": "^6.0", "vue": "^3.5.13", @@ -32,7 +32,7 @@ "@inertiajs/server": "^0.1.0", "@vueuse/core": "^12.5.0", "laravel-vue-i18n": "^2.7.8", - "swiper": "^11.2.1", + "swiper": "^11.2.2", "vue": "^3.5.13" }, "prettier": { diff --git a/resources/js/Pages/MyEvents.vue b/resources/js/Pages/MyEvents.vue index 381eb81..1e5d9aa 100755 --- a/resources/js/Pages/MyEvents.vue +++ b/resources/js/Pages/MyEvents.vue @@ -23,6 +23,7 @@ interface EventPagination { } const events = (usePage().props.events as EventPagination).data as IcsEvent[]; +const feedbackEvent = ref(null); const paginationLinks = (usePage().props.events as EventPagination).links as Links; @@ -84,16 +85,16 @@ const paginationLinks = (usePage().props.events as EventPagination).links as Lin > -
+
+ src="/feedback.png" alt="feedback"/>
- +
diff --git a/tests/Feature/Http/Controllers/Auth/AuthenticationTest.php b/tests/Feature/Http/Controllers/Auth/AuthenticationTest.php index 0bad501..d625398 100755 --- a/tests/Feature/Http/Controllers/Auth/AuthenticationTest.php +++ b/tests/Feature/Http/Controllers/Auth/AuthenticationTest.php @@ -37,19 +37,19 @@ }); test('guests are redirected from protected pages to login', function () { - get(route('dashboard'))->assertRedirectToRoute('login'); +get(route('dashboard'))->assertRedirectToRoute('login'); get(route('generate'))->assertRedirectToRoute('login'); get(route('my-events'))->assertRedirectToRoute('login'); get(route('profile.edit'))->assertRedirectToRoute('login'); -}); + }); test('fallback route redirects to home page', function () { - get('/' . Str::random(25))->assertRedirectToRoute('home'); -}); +get('/' . Str::random(25))->assertRedirectToRoute('home'); + }); test('login screen can be rendered', function () { - get('/login')->assertOk(); -}); +get('/login')->assertOk(); + }); test('users can authenticate using the login screen', function () { $user = User::factory()->create(); diff --git a/tests/Feature/Http/Controllers/Auth/PasswordResetTest.php b/tests/Feature/Http/Controllers/Auth/PasswordResetTest.php index a87b453..6e0334d 100755 --- a/tests/Feature/Http/Controllers/Auth/PasswordResetTest.php +++ b/tests/Feature/Http/Controllers/Auth/PasswordResetTest.php @@ -8,8 +8,8 @@ use function Pest\Laravel\post; test('reset password link screen can be rendered', function () { - get('/forgot-password')->assertOk(); -}); +get('/forgot-password')->assertOk(); + }); test('reset password link can be requested', function () { Notification::fake(); @@ -29,10 +29,10 @@ post('/forgot-password', ['email' => $user->email]); Notification::assertSentTo($user, ResetPassword::class, function ($notification) { - get('/reset-password/' . $notification->token)->assertOk(); + get('/reset-password/' . $notification->token)->assertOk(); return true; - }); + }); }); test('password can be reset with valid token', function () { diff --git a/tests/Feature/Http/Controllers/Auth/RegistrationTest.php b/tests/Feature/Http/Controllers/Auth/RegistrationTest.php index 0e6d325..438cf14 100755 --- a/tests/Feature/Http/Controllers/Auth/RegistrationTest.php +++ b/tests/Feature/Http/Controllers/Auth/RegistrationTest.php @@ -5,9 +5,9 @@ test('registration screen can be rendered', function () { - get(route('login')) - ->assertStatus(200); -}); +get(route('login')) +->assertStatus(200); + }); test('new users can register', function () { post('/register', [ diff --git a/tests/Feature/Http/Controllers/DashboardControllerTest.php b/tests/Feature/Http/Controllers/DashboardControllerTest.php index 6e89fa2..9b36e0f 100755 --- a/tests/Feature/Http/Controllers/DashboardControllerTest.php +++ b/tests/Feature/Http/Controllers/DashboardControllerTest.php @@ -9,7 +9,7 @@ test('users can access dashboard, guests cannot', function () { - get(route('dashboard'))->assertRedirect(); +get(route('dashboard'))->assertRedirect(); $user = User::factory()->create(); @@ -25,7 +25,7 @@ ->where('buyCreditsLink', 'https://payment.link/topup') ->where('paymentConfirmation', null) ); -}); + }); test('dashboard popups are generated correctly from route parameters', function () { diff --git a/tests/Feature/Http/Controllers/FeedbackControllerTest.php b/tests/Feature/Http/Controllers/FeedbackControllerTest.php index 716950e..3e6aaf8 100644 --- a/tests/Feature/Http/Controllers/FeedbackControllerTest.php +++ b/tests/Feature/Http/Controllers/FeedbackControllerTest.php @@ -102,6 +102,11 @@ 'data' => 'test', ])->assertUnprocessable()->assertJsonValidationErrors(['like']); + /** @var IcsEvent $icsEvent */ + actingAs($user)->postJson(route('feedback'), data: [ + 'data' => '', + ])->assertUnprocessable()->assertJsonValidationErrors(['like', 'data', 'ics_event_id']); + /** @var IcsEvent $icsEvent */ actingAs($user)->postJson(route('feedback'), data: [ 'ics_event_id' => $icsEvent->id, diff --git a/tests/Feature/Http/Controllers/SubscriptionControllerTest.php b/tests/Feature/Http/Controllers/SubscriptionControllerTest.php index 5dd59e2..fbd0495 100755 --- a/tests/Feature/Http/Controllers/SubscriptionControllerTest.php +++ b/tests/Feature/Http/Controllers/SubscriptionControllerTest.php @@ -9,11 +9,11 @@ use function Pest\Laravel\post; test("guests can't access subscription links", function () { - get(route('subscriptions.get-modification-data'))->assertRedirect(); +get(route('subscriptions.get-modification-data'))->assertRedirect(); post(route('subscriptions.subscribe'), ['type' => 'beginner'])->assertRedirect(); post(route('subscriptions.cancel'))->assertRedirect(); post(route('subscriptions.swap'), ['newSubscription' => 'beginner'])->assertRedirect(); -}); + }); test('subscription links are created for users', function () { diff --git a/tests/Feature/Http/Controllers/TelegramControllerTest.php b/tests/Feature/Http/Controllers/TelegramControllerTest.php index bdd9a3a..32fe84d 100755 --- a/tests/Feature/Http/Controllers/TelegramControllerTest.php +++ b/tests/Feature/Http/Controllers/TelegramControllerTest.php @@ -96,7 +96,7 @@ test('users can add a telegram account, guests cannot', function () { - get(route('telegram.connect'))->assertRedirectToRoute('login'); +get(route('telegram.connect'))->assertRedirectToRoute('login'); $user = User::factory()->create(); $telegramId = fake()->randomNumber(6); @@ -119,7 +119,7 @@ expect($user->telegram_id)->toEqual($telegramId); Notification::assertSentTo($user, CustomMessage::class); -}); + }); test('telegram webhook is processed only with a valid secret token header', function () { diff --git a/tests/Feature/MainPagesTest.php b/tests/Feature/MainPagesTest.php index e411a9d..45b5968 100755 --- a/tests/Feature/MainPagesTest.php +++ b/tests/Feature/MainPagesTest.php @@ -13,11 +13,11 @@ test('Guest-only pages are displayed to guests and redirect users', function (string $route, string $component, string $redirectRoute) { - get(route($route))->assertOk() - ->assertInertia(fn (AssertableInertia $page) => $page->component($component)); + get(route($route))->assertOk() + ->assertInertia(fn (AssertableInertia $page) => $page->component($component)); - $user = User::factory()->create(); - actingAs($user)->get(route($route))->assertRedirectToRoute($redirectRoute); + $user = User::factory()->create(); + actingAs($user)->get(route($route))->assertRedirectToRoute($redirectRoute); })->with([ [ 'route' => 'home', @@ -37,15 +37,15 @@ function (string $route, string $component, string $redirectRoute) { ]); test('terms of service and privacy policy pages are displayed', function (string $route) { - get(route($route))->assertOk(); -})->with(['route' => 'terms-of-service'], ['route' => 'privacy-policy']); +get(route($route))->assertOk(); + })->with(['route' => 'terms-of-service'], ['route' => 'privacy-policy']); test('Horizon and Pulse pages are only accessible to admin', function (string $uri) { - get($uri)->assertRedirectToRoute('home'); +get($uri)->assertRedirectToRoute('home'); $user = User::factory()->create(); actingAs($user)->get($uri)->assertRedirectToRoute('how-to-use'); $admin = User::factory()->create(['email' => config('app.admin.email')]); actingAs($admin)->get($uri)->assertOk(); -})->with(['uri' => '/horizon'], ['uri' => '/pulse']); + })->with(['uri' => '/horizon'], ['uri' => '/pulse']);