From db8e34b622a69aa6543a0752b2f501aae46f62a0 Mon Sep 17 00:00:00 2001 From: = Date: Thu, 14 May 2026 08:47:23 +0000 Subject: [PATCH] feat: integrate maryUI and update ConnectedApps handling - Added `mary.php` configuration file for customizable component and route prefixes. - Upgraded `livewire/livewire` to v4.3 and added `robsontenorio/mary` v2.8 for maryUI support. - Updated `ConnectedApps` component to fetch data dynamically via `ConnectedAppService`. - Replaced static services with computed properties and streamlined data mappings in templates. - Enhanced frontend styling with `daisyUI` and TailwindCSS v4.3 integration. - Improved user feedback in `ConnectedAppForm` with success/error toasts. --- .../ConnectedApp/ConnectionStatusData.php | 9 +- .../Ui/ConnectedApps/ConnectedAppData.php | 31 ++ .../ConnectedServiceData.php | 19 - app/Models/ConnectedApp.php | 6 +- app/Services/ConnectedAppService.php | 13 + app/Services/ConnectionStatusService.php | 3 + composer.json | 3 +- composer.lock | 394 +++++++++++++++++- config/mary.php | 46 ++ database/seeders/ConnectionProtocolSeeder.php | 2 +- package-lock.json | 198 +++++---- package.json | 7 +- resources/css/app.css | 68 ++- .../dashboard/connected-apps/⚡all.blade.php | 65 +-- .../connected-apps/⚡connected-apps.blade.php | 21 +- resources/views/layouts/app/sidebar.blade.php | 1 + .../pages/connected-apps/⚡create.blade.php | 5 + 17 files changed, 731 insertions(+), 160 deletions(-) create mode 100644 app/Data/Ui/ConnectedApps/ConnectedAppData.php delete mode 100644 app/Data/Ui/ConnectedServices/ConnectedServiceData.php create mode 100644 config/mary.php diff --git a/app/Data/ConnectedApp/ConnectionStatusData.php b/app/Data/ConnectedApp/ConnectionStatusData.php index fd3c005..8b84097 100644 --- a/app/Data/ConnectedApp/ConnectionStatusData.php +++ b/app/Data/ConnectedApp/ConnectionStatusData.php @@ -1,10 +1,11 @@ id, + name: $app->name, + protocol: ConnectionProtocolEnum::tryFrom($app->protocol->name), + provider: $app->provider?->name, + status: ConnectionStatusEnum::tryFrom($app->status->name) + ); + } +} diff --git a/app/Data/Ui/ConnectedServices/ConnectedServiceData.php b/app/Data/Ui/ConnectedServices/ConnectedServiceData.php deleted file mode 100644 index 141447a..0000000 --- a/app/Data/Ui/ConnectedServices/ConnectedServiceData.php +++ /dev/null @@ -1,19 +0,0 @@ -hasOne(ConnectionProtocol::class, 'id', 'service_protocol_id'); + return $this->hasOne(ConnectionProtocol::class, 'id', 'connection_protocol_id'); } public function provider(): HasOne { - return $this->hasOne(ConnectionProvider::class, 'id', 'service_provider_id'); + return $this->hasOne(ConnectionProvider::class, 'id', 'connection_provider_id'); } public function status(): HasOne { - return $this->hasOne(ConnectionStatus::class, 'id', 'service_status_id'); + return $this->hasOne(ConnectionStatus::class, 'id', 'connection_status_id'); } } diff --git a/app/Services/ConnectedAppService.php b/app/Services/ConnectedAppService.php index 7afabd8..094f829 100644 --- a/app/Services/ConnectedAppService.php +++ b/app/Services/ConnectedAppService.php @@ -5,14 +5,17 @@ namespace App\Services; use App\Data\ConnectedApp\ConnectAppRequest; +use App\Data\Ui\ConnectedApps\ConnectedAppData; use App\Models\ConnectedApp; use Illuminate\Support\Facades\DB; +use Spatie\LaravelData\DataCollection; use Throwable; final class ConnectedAppService { /** * Create a new connected app. + * * @throws Throwable */ public function create(ConnectAppRequest $data): void @@ -23,4 +26,14 @@ public function create(ConnectAppRequest $data): void ) ); } + + /** + * @return DataCollection + */ + public function getAll(): DataCollection + { + $data = ConnectedApp::with('provider', 'protocol', 'status')->get(); + + return ConnectedAppData::collect($data, DataCollection::class); + } } diff --git a/app/Services/ConnectionStatusService.php b/app/Services/ConnectionStatusService.php index 424b6fc..aebc687 100644 --- a/app/Services/ConnectionStatusService.php +++ b/app/Services/ConnectionStatusService.php @@ -1,5 +1,7 @@ get(); + return ConnectionStatusData::collect($statuses, DataCollection::class); } } diff --git a/composer.json b/composer.json index 0a4cf8e..7654752 100644 --- a/composer.json +++ b/composer.json @@ -15,8 +15,9 @@ "laravel/framework": "^13.7", "laravel/tinker": "^3.0", "livewire/flux": "^2.13.1", - "livewire/livewire": "^4.1", + "livewire/livewire": "^4.3", "mallardduck/blade-lucide-icons": "^1.26", + "robsontenorio/mary": "^2.8", "spatie/laravel-data": "^4.22", "spatie/laravel-permission": "^7.4" }, diff --git a/composer.lock b/composer.lock index b10e264..cbf3ddd 100644 --- 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": "c67b7d3d288d70102f45a51aac214c15", + "content-hash": "87c14752eaead13e07a445ce4a569510", "packages": [ { "name": "bacon/bacon-qr-code", @@ -61,6 +61,75 @@ }, "time": "2026-04-05T21:06:35+00:00" }, + { + "name": "blade-ui-kit/blade-heroicons", + "version": "2.7.0", + "source": { + "type": "git", + "url": "https://github.com/driesvints/blade-heroicons.git", + "reference": "66fa8ba09dba12e0cdb410b8cb94f3b890eca440" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/driesvints/blade-heroicons/zipball/66fa8ba09dba12e0cdb410b8cb94f3b890eca440", + "reference": "66fa8ba09dba12e0cdb410b8cb94f3b890eca440", + "shasum": "" + }, + "require": { + "blade-ui-kit/blade-icons": "^1.6", + "illuminate/support": "^9.0|^10.0|^11.0|^12.0|^13.0", + "php": "^8.0" + }, + "require-dev": { + "orchestra/testbench": "^7.0|^8.0|^9.0|^10.0|^11.0", + "phpunit/phpunit": "^9.0|^10.5|^11.0|^12.0" + }, + "type": "library", + "extra": { + "laravel": { + "providers": [ + "BladeUI\\Heroicons\\BladeHeroiconsServiceProvider" + ] + } + }, + "autoload": { + "psr-4": { + "BladeUI\\Heroicons\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Dries Vints", + "homepage": "https://driesvints.com" + } + ], + "description": "A package to easily make use of Heroicons in your Laravel Blade views.", + "homepage": "https://github.com/driesvints/blade-heroicons", + "keywords": [ + "Heroicons", + "blade", + "laravel" + ], + "support": { + "issues": "https://github.com/driesvints/blade-heroicons/issues", + "source": "https://github.com/driesvints/blade-heroicons/tree/2.7.0" + }, + "funding": [ + { + "url": "https://github.com/sponsors/driesvints", + "type": "github" + }, + { + "url": "https://www.paypal.com/paypalme/driesvints", + "type": "paypal" + } + ], + "time": "2026-03-16T13:00:23+00:00" + }, { "name": "blade-ui-kit/blade-icons", "version": "1.10.0", @@ -1428,6 +1497,243 @@ ], "time": "2025-08-22T14:27:06+00:00" }, + { + "name": "jfcherng/php-color-output", + "version": "3.0.0", + "source": { + "type": "git", + "url": "https://github.com/jfcherng/php-color-output.git", + "reference": "6c7bf16686cc6a291647fcb87491640a2d5edd20" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/jfcherng/php-color-output/zipball/6c7bf16686cc6a291647fcb87491640a2d5edd20", + "reference": "6c7bf16686cc6a291647fcb87491640a2d5edd20", + "shasum": "" + }, + "require": { + "php": ">=7.1.3" + }, + "require-dev": { + "friendsofphp/php-cs-fixer": "^2.19", + "liip/rmt": "^1.6", + "phan/phan": "^2 || ^3 || ^4", + "phpunit/phpunit": ">=7 <10", + "squizlabs/php_codesniffer": "^3.5" + }, + "type": "library", + "autoload": { + "psr-4": { + "Jfcherng\\Utility\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jack Cherng", + "email": "jfcherng@gmail.com" + } + ], + "description": "Make your PHP command-line application colorful.", + "keywords": [ + "ansi-colors", + "color", + "command-line", + "str-color" + ], + "support": { + "issues": "https://github.com/jfcherng/php-color-output/issues", + "source": "https://github.com/jfcherng/php-color-output/tree/3.0.0" + }, + "funding": [ + { + "url": "https://www.paypal.me/jfcherng/5usd", + "type": "custom" + } + ], + "time": "2021-05-27T02:45:54+00:00" + }, + { + "name": "jfcherng/php-diff", + "version": "6.16.2", + "source": { + "type": "git", + "url": "https://github.com/jfcherng/php-diff.git", + "reference": "7f46bcfc582e81769237d0b3f6b8a548efe8799d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/jfcherng/php-diff/zipball/7f46bcfc582e81769237d0b3f6b8a548efe8799d", + "reference": "7f46bcfc582e81769237d0b3f6b8a548efe8799d", + "shasum": "" + }, + "require": { + "jfcherng/php-color-output": "^3", + "jfcherng/php-mb-string": "^1.4.6 || ^2", + "jfcherng/php-sequence-matcher": "^3.2.10 || ^4", + "php": ">=7.4" + }, + "require-dev": { + "friendsofphp/php-cs-fixer": "^3.51", + "liip/rmt": "^1.6", + "phan/phan": "^5", + "phpunit/phpunit": "^9", + "squizlabs/php_codesniffer": "^3.6" + }, + "type": "library", + "autoload": { + "psr-4": { + "Jfcherng\\Diff\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Jack Cherng", + "email": "jfcherng@gmail.com" + }, + { + "name": "Chris Boulton", + "email": "chris.boulton@interspire.com" + } + ], + "description": "A comprehensive library for generating differences between two strings in multiple formats (unified, side by side HTML etc).", + "keywords": [ + "diff", + "udiff", + "unidiff", + "unified diff" + ], + "support": { + "issues": "https://github.com/jfcherng/php-diff/issues", + "source": "https://github.com/jfcherng/php-diff/tree/6.16.2" + }, + "funding": [ + { + "url": "https://www.paypal.me/jfcherng/5usd", + "type": "custom" + } + ], + "time": "2024-03-10T17:40:29+00:00" + }, + { + "name": "jfcherng/php-mb-string", + "version": "2.0.1", + "source": { + "type": "git", + "url": "https://github.com/jfcherng/php-mb-string.git", + "reference": "8407bfefde47849c9e7c9594e6de2ac85a0f845d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/jfcherng/php-mb-string/zipball/8407bfefde47849c9e7c9594e6de2ac85a0f845d", + "reference": "8407bfefde47849c9e7c9594e6de2ac85a0f845d", + "shasum": "" + }, + "require": { + "ext-iconv": "*", + "php": ">=8.1" + }, + "require-dev": { + "friendsofphp/php-cs-fixer": "^3", + "phan/phan": "^5", + "phpunit/phpunit": "^9 || ^10" + }, + "suggest": { + "ext-iconv": "Either \"ext-iconv\" or \"ext-mbstring\" is requried.", + "ext-mbstring": "Either \"ext-iconv\" or \"ext-mbstring\" is requried." + }, + "type": "library", + "autoload": { + "psr-4": { + "Jfcherng\\Utility\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jack Cherng", + "email": "jfcherng@gmail.com" + } + ], + "description": "A high performance multibytes sting implementation for frequently reading/writing operations.", + "support": { + "issues": "https://github.com/jfcherng/php-mb-string/issues", + "source": "https://github.com/jfcherng/php-mb-string/tree/2.0.1" + }, + "funding": [ + { + "url": "https://www.paypal.me/jfcherng/5usd", + "type": "custom" + } + ], + "time": "2023-04-17T14:23:16+00:00" + }, + { + "name": "jfcherng/php-sequence-matcher", + "version": "4.0.3", + "source": { + "type": "git", + "url": "https://github.com/jfcherng/php-sequence-matcher.git", + "reference": "d2038ac29627340a7458609072a8ba355e80ec5b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/jfcherng/php-sequence-matcher/zipball/d2038ac29627340a7458609072a8ba355e80ec5b", + "reference": "d2038ac29627340a7458609072a8ba355e80ec5b", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "friendsofphp/php-cs-fixer": "^3", + "phan/phan": "^5", + "phpunit/phpunit": "^9 || ^10", + "squizlabs/php_codesniffer": "^3.7" + }, + "type": "library", + "autoload": { + "psr-4": { + "Jfcherng\\Diff\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Jack Cherng", + "email": "jfcherng@gmail.com" + }, + { + "name": "Chris Boulton", + "email": "chris.boulton@interspire.com" + } + ], + "description": "A longest sequence matcher. The logic is primarily based on the Python difflib package.", + "support": { + "issues": "https://github.com/jfcherng/php-sequence-matcher/issues", + "source": "https://github.com/jfcherng/php-sequence-matcher/tree/4.0.3" + }, + "funding": [ + { + "url": "https://www.paypal.me/jfcherng/5usd", + "type": "custom" + } + ], + "time": "2023-05-21T07:57:08+00:00" + }, { "name": "laravel/fortify", "version": "v1.37.0", @@ -4352,6 +4658,92 @@ }, "time": "2025-12-14T04:43:48+00:00" }, + { + "name": "robsontenorio/mary", + "version": "2.8.2", + "source": { + "type": "git", + "url": "https://github.com/robsontenorio/mary.git", + "reference": "fee6e23a158c54c682b5dd5d7c9377ba4889761a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/robsontenorio/mary/zipball/fee6e23a158c54c682b5dd5d7c9377ba4889761a", + "reference": "fee6e23a158c54c682b5dd5d7c9377ba4889761a", + "shasum": "" + }, + "require": { + "blade-ui-kit/blade-heroicons": "^2.6", + "illuminate/support": "^10.0|^11.0|^12.0|^13.0", + "jfcherng/php-diff": "^6.15", + "laravel/prompts": "^0|^1" + }, + "require-dev": { + "orchestra/testbench": "^8|^9|^10|^11.0", + "phpunit/phpunit": "^10|^11|^12.5.12" + }, + "type": "library", + "extra": { + "laravel": { + "aliases": { + "Mary": "Mary\\Facades\\Mary" + }, + "providers": [ + "Mary\\MaryServiceProvider" + ] + } + }, + "autoload": { + "psr-4": { + "Mary\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Robson Tenório", + "email": "rrtenorio@gmail.com", + "homepage": "https://github.com/robsontenorio" + } + ], + "description": "Gorgeous UI components for Livewire powered by daisyUI and Tailwind", + "homepage": "https://mary-ui.com", + "keywords": [ + "DaisyUI", + "alpinejs", + "blade", + "blade ui components", + "components", + "laravel", + "livewire", + "livewire components", + "livewire packages", + "livewire ui", + "livewire ui components", + "livewire-components", + "livewire-packages", + "tailwind", + "tallstack", + "tallstack components", + "tallstack ui", + "tallstackui", + "ui" + ], + "support": { + "issues": "https://github.com/robsontenorio/mary/issues", + "source": "https://github.com/robsontenorio/mary/tree/2.8.2" + }, + "funding": [ + { + "url": "https://github.com/robsontenorio", + "type": "github" + } + ], + "time": "2026-04-17T13:40:53+00:00" + }, { "name": "spatie/laravel-data", "version": "4.23.0", diff --git a/config/mary.php b/config/mary.php new file mode 100644 index 0000000..0324934 --- /dev/null +++ b/config/mary.php @@ -0,0 +1,46 @@ + '' + * + * + * + * prefix => 'mary-' + * + * + */ + 'prefix' => 'mary-', + + /** + * Default route prefix. + * + * Some maryUI components make network request to its internal routes. + * + * route_prefix => '' + * - Spotlight: '/mary/spotlight' + * - Editor: '/mary/upload' + * - ... + * + * route_prefix => 'my-components' + * - Spotlight: '/my-components/mary/spotlight' + * - Editor: '/my-components/mary/upload' + * - ... + */ + 'route_prefix' => '', + + /** + * Components settings + */ + 'components' => [ + 'spotlight' => [ + 'class' => 'App\Support\Spotlight', + ], + ], +]; diff --git a/database/seeders/ConnectionProtocolSeeder.php b/database/seeders/ConnectionProtocolSeeder.php index f4473ae..019b071 100644 --- a/database/seeders/ConnectionProtocolSeeder.php +++ b/database/seeders/ConnectionProtocolSeeder.php @@ -4,7 +4,7 @@ namespace Database\Seeders; -use App\Enums\{ConnectionProtocolEnum}; +use App\Enums\ConnectionProtocolEnum; use App\Models\ConnectionProtocol; use Illuminate\Database\Seeder; diff --git a/package-lock.json b/package-lock.json index 780563d..7c7a8bd 100644 --- a/package-lock.json +++ b/package-lock.json @@ -5,13 +5,16 @@ "packages": { "": { "dependencies": { - "@tailwindcss/vite": "^4.1.11", "autoprefixer": "^10.4.20", "concurrently": "^9.0.1", "laravel-vite-plugin": "^3.1", - "tailwindcss": "^4.0.7", "vite": "^8.0.0" }, + "devDependencies": { + "@tailwindcss/vite": "^4.3.0", + "daisyui": "^5.5.19", + "tailwindcss": "^4.3.0" + }, "optionalDependencies": { "@rollup/rollup-linux-x64-gnu": "4.9.5", "@tailwindcss/oxide-linux-x64-gnu": "^4.0.1", @@ -53,6 +56,7 @@ "version": "0.3.13", "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.13.tgz", "integrity": "sha512-2kkt/7niJ6MgEPxF0bYdQ6etZaA+fQvDcLKckhy1yIQOzaoKjBBjSj63/aLVjYE3qhRt5dvM+uUyfCg6UKCBbA==", + "dev": true, "license": "MIT", "dependencies": { "@jridgewell/sourcemap-codec": "^1.5.0", @@ -63,6 +67,7 @@ "version": "2.3.5", "resolved": "https://registry.npmjs.org/@jridgewell/remapping/-/remapping-2.3.5.tgz", "integrity": "sha512-LI9u/+laYG4Ds1TDKSJW2YPrIlcVYOwi2fUC6xB43lueCjgxV4lffOCZCtYFiH6TNOX+tQKXx97T4IKHbhyHEQ==", + "dev": true, "license": "MIT", "dependencies": { "@jridgewell/gen-mapping": "^0.3.5", @@ -73,6 +78,7 @@ "version": "3.1.2", "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", + "dev": true, "license": "MIT", "engines": { "node": ">=6.0.0" @@ -82,12 +88,14 @@ "version": "1.5.5", "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz", "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==", + "dev": true, "license": "MIT" }, "node_modules/@jridgewell/trace-mapping": { "version": "0.3.31", "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.31.tgz", "integrity": "sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==", + "dev": true, "license": "MIT", "dependencies": { "@jridgewell/resolve-uri": "^3.1.0", @@ -383,50 +391,53 @@ ] }, "node_modules/@tailwindcss/node": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/node/-/node-4.2.4.tgz", - "integrity": "sha512-Ai7+yQPxz3ddrDQzFfBKdHEVBg0w3Zl83jnjuwxnZOsnH9pGn93QHQtpU0p/8rYWxvbFZHneni6p1BSLK4DkGA==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/node/-/node-4.3.0.tgz", + "integrity": "sha512-aFb4gUhFOgdh9AXo4IzBEOzBkkAxm9VigwDJnMIYv3lcfXCJVesNfbEaBl4BNgVRyid92AmdviqwBUBRKSeY3g==", + "dev": true, "license": "MIT", "dependencies": { "@jridgewell/remapping": "^2.3.5", - "enhanced-resolve": "^5.19.0", + "enhanced-resolve": "^5.21.0", "jiti": "^2.6.1", "lightningcss": "1.32.0", "magic-string": "^0.30.21", "source-map-js": "^1.2.1", - "tailwindcss": "4.2.4" + "tailwindcss": "4.3.0" } }, "node_modules/@tailwindcss/oxide": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide/-/oxide-4.2.4.tgz", - "integrity": "sha512-9El/iI069DKDSXwTvB9J4BwdO5JhRrOweGaK25taBAvBXyXqJAX+Jqdvs8r8gKpsI/1m0LeJLyQYTf/WLrBT1Q==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide/-/oxide-4.3.0.tgz", + "integrity": "sha512-F7HZGBeN9I0/AuuJS5PwcD8xayx5ri5GhjYUDBEVYUkexyA/giwbDNjRVrxSezE3T250OU2K/wp/ltWx3UOefg==", + "dev": true, "license": "MIT", "engines": { "node": ">= 20" }, "optionalDependencies": { - "@tailwindcss/oxide-android-arm64": "4.2.4", - "@tailwindcss/oxide-darwin-arm64": "4.2.4", - "@tailwindcss/oxide-darwin-x64": "4.2.4", - "@tailwindcss/oxide-freebsd-x64": "4.2.4", - "@tailwindcss/oxide-linux-arm-gnueabihf": "4.2.4", - "@tailwindcss/oxide-linux-arm64-gnu": "4.2.4", - "@tailwindcss/oxide-linux-arm64-musl": "4.2.4", - "@tailwindcss/oxide-linux-x64-gnu": "4.2.4", - "@tailwindcss/oxide-linux-x64-musl": "4.2.4", - "@tailwindcss/oxide-wasm32-wasi": "4.2.4", - "@tailwindcss/oxide-win32-arm64-msvc": "4.2.4", - "@tailwindcss/oxide-win32-x64-msvc": "4.2.4" + "@tailwindcss/oxide-android-arm64": "4.3.0", + "@tailwindcss/oxide-darwin-arm64": "4.3.0", + "@tailwindcss/oxide-darwin-x64": "4.3.0", + "@tailwindcss/oxide-freebsd-x64": "4.3.0", + "@tailwindcss/oxide-linux-arm-gnueabihf": "4.3.0", + "@tailwindcss/oxide-linux-arm64-gnu": "4.3.0", + "@tailwindcss/oxide-linux-arm64-musl": "4.3.0", + "@tailwindcss/oxide-linux-x64-gnu": "4.3.0", + "@tailwindcss/oxide-linux-x64-musl": "4.3.0", + "@tailwindcss/oxide-wasm32-wasi": "4.3.0", + "@tailwindcss/oxide-win32-arm64-msvc": "4.3.0", + "@tailwindcss/oxide-win32-x64-msvc": "4.3.0" } }, "node_modules/@tailwindcss/oxide-android-arm64": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-android-arm64/-/oxide-android-arm64-4.2.4.tgz", - "integrity": "sha512-e7MOr1SAn9U8KlZzPi1ZXGZHeC5anY36qjNwmZv9pOJ8E4Q6jmD1vyEHkQFmNOIN7twGPEMXRHmitN4zCMN03g==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-android-arm64/-/oxide-android-arm64-4.3.0.tgz", + "integrity": "sha512-TJPiq67tKlLuObP6RkwvVGDoxCMBVtDgKkLfa/uyj7/FyxvQwHS+UOnVrXXgbEsfUaMgiVvC4KbJnRr26ho4Ng==", "cpu": [ "arm64" ], + "dev": true, "license": "MIT", "optional": true, "os": [ @@ -437,12 +448,13 @@ } }, "node_modules/@tailwindcss/oxide-darwin-arm64": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-arm64/-/oxide-darwin-arm64-4.2.4.tgz", - "integrity": "sha512-tSC/Kbqpz/5/o/C2sG7QvOxAKqyd10bq+ypZNf+9Fi2TvbVbv1zNpcEptcsU7DPROaSbVgUXmrzKhurFvo5eDg==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-arm64/-/oxide-darwin-arm64-4.3.0.tgz", + "integrity": "sha512-oMN/WZRb+SO37BmUElEgeEWuU8E/HXRkiODxJxLe1UTHVXLrdVSgfaJV7pSlhRGMSOiXLuxTIjfsF3wYvz8cgQ==", "cpu": [ "arm64" ], + "dev": true, "license": "MIT", "optional": true, "os": [ @@ -453,12 +465,13 @@ } }, "node_modules/@tailwindcss/oxide-darwin-x64": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-x64/-/oxide-darwin-x64-4.2.4.tgz", - "integrity": "sha512-yPyUXn3yO/ufR6+Kzv0t4fCg2qNr90jxXc5QqBpjlPNd0NqyDXcmQb/6weunH/MEDXW5dhyEi+agTDiqa3WsGg==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-x64/-/oxide-darwin-x64-4.3.0.tgz", + "integrity": "sha512-N6CUmu4a6bKVADfw77p+iw6Yd9Q3OBhe0veaDX+QazfuVYlQsHfDgxBrsjQ/IW+zywL8mTrNd0SdJT/zgtvMdA==", "cpu": [ "x64" ], + "dev": true, "license": "MIT", "optional": true, "os": [ @@ -469,12 +482,13 @@ } }, "node_modules/@tailwindcss/oxide-freebsd-x64": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-freebsd-x64/-/oxide-freebsd-x64-4.2.4.tgz", - "integrity": "sha512-BoMIB4vMQtZsXdGLVc2z+P9DbETkiopogfWZKbWwM8b/1Vinbs4YcUwo+kM/KeLkX3Ygrf4/PsRndKaYhS8Eiw==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-freebsd-x64/-/oxide-freebsd-x64-4.3.0.tgz", + "integrity": "sha512-zDL5hBkQdH5C6MpqbK3gQAgP80tsMwSI26vjOzjJtNCMUo0lFgOItzHKBIupOZNQxt3ouPH7RPhvNhiTfCe5CQ==", "cpu": [ "x64" ], + "dev": true, "license": "MIT", "optional": true, "os": [ @@ -485,12 +499,13 @@ } }, "node_modules/@tailwindcss/oxide-linux-arm-gnueabihf": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm-gnueabihf/-/oxide-linux-arm-gnueabihf-4.2.4.tgz", - "integrity": "sha512-7pIHBLTHYRAlS7V22JNuTh33yLH4VElwKtB3bwchK/UaKUPpQ0lPQiOWcbm4V3WP2I6fNIJ23vABIvoy2izdwA==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm-gnueabihf/-/oxide-linux-arm-gnueabihf-4.3.0.tgz", + "integrity": "sha512-R06HdNi7A7OEoMsf6d4tjZ71RCWnZQPHj2mnotSFURjNLdBC+cIgXQ7l81CqeoiQftjf6OOblxXMInMgN2VzMA==", "cpu": [ "arm" ], + "dev": true, "license": "MIT", "optional": true, "os": [ @@ -501,12 +516,16 @@ } }, "node_modules/@tailwindcss/oxide-linux-arm64-gnu": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-gnu/-/oxide-linux-arm64-gnu-4.2.4.tgz", - "integrity": "sha512-+E4wxJ0ZGOzSH325reXTWB48l42i93kQqMvDyz5gqfRzRZ7faNhnmvlV4EPGJU3QJM/3Ab5jhJ5pCRUsKn6OQw==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-gnu/-/oxide-linux-arm64-gnu-4.3.0.tgz", + "integrity": "sha512-qTJHELX8jetjhRQHCLilkVLmybpzNQAtaI/gaoVoidn/ufbNDbAo8KlK2J+yPoc8wQxvDxCmh/5lr8nC1+lTbg==", "cpu": [ "arm64" ], + "dev": true, + "libc": [ + "glibc" + ], "license": "MIT", "optional": true, "os": [ @@ -517,12 +536,16 @@ } }, "node_modules/@tailwindcss/oxide-linux-arm64-musl": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-musl/-/oxide-linux-arm64-musl-4.2.4.tgz", - "integrity": "sha512-bBADEGAbo4ASnppIziaQJelekCxdMaxisrk+fB7Thit72IBnALp9K6ffA2G4ruj90G9XRS2VQ6q2bCKbfFV82g==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-musl/-/oxide-linux-arm64-musl-4.3.0.tgz", + "integrity": "sha512-Z6sukiQsngnWO+l39X4pPbiWT81IC+PLKF+PHxIlyZbGNb9MODfYlXEVlFvej5BOZInWX01kVyzeLvHsXhfczQ==", "cpu": [ "arm64" ], + "dev": true, + "libc": [ + "musl" + ], "license": "MIT", "optional": true, "os": [ @@ -533,12 +556,15 @@ } }, "node_modules/@tailwindcss/oxide-linux-x64-gnu": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-gnu/-/oxide-linux-x64-gnu-4.2.4.tgz", - "integrity": "sha512-7Mx25E4WTfnht0TVRTyC00j3i0M+EeFe7wguMDTlX4mRxafznw0CA8WJkFjWYH5BlgELd1kSjuU2JiPnNZbJDA==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-gnu/-/oxide-linux-x64-gnu-4.3.0.tgz", + "integrity": "sha512-DRNdQRpSGzRGfARVuVkxvM8Q12nh19l4BF/G7zGA1oe+9wcC6saFBHTISrpIcKzhiXtSrlSrluCfvMuledoCTQ==", "cpu": [ "x64" ], + "libc": [ + "glibc" + ], "license": "MIT", "optional": true, "os": [ @@ -549,12 +575,16 @@ } }, "node_modules/@tailwindcss/oxide-linux-x64-musl": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-musl/-/oxide-linux-x64-musl-4.2.4.tgz", - "integrity": "sha512-2wwJRF7nyhOR0hhHoChc04xngV3iS+akccHTGtz965FwF0up4b2lOdo6kI1EbDaEXKgvcrFBYcYQQ/rrnWFVfA==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-musl/-/oxide-linux-x64-musl-4.3.0.tgz", + "integrity": "sha512-Z0IADbDo8bh6I7h2IQMx601AdXBLfFpEdUotft86evd/8ZPflZe9COPO8Q1vw+pfLWIUo9zN/JGZvwuAJqduqg==", "cpu": [ "x64" ], + "dev": true, + "libc": [ + "musl" + ], "license": "MIT", "optional": true, "os": [ @@ -565,9 +595,9 @@ } }, "node_modules/@tailwindcss/oxide-wasm32-wasi": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-wasm32-wasi/-/oxide-wasm32-wasi-4.2.4.tgz", - "integrity": "sha512-FQsqApeor8Fo6gUEklzmaa9994orJZZDBAlQpK2Mq+DslRKFJeD6AjHpBQ0kZFQohVr8o85PPh8eOy86VlSCmw==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-wasm32-wasi/-/oxide-wasm32-wasi-4.3.0.tgz", + "integrity": "sha512-HNZGOUxEmElksYR7S6sC5jTeNGpobAsy9u7Gu0AskJ8/20FR9GqebUyB+HBcU/ax6BHuiuJi+Oda4B+YX6H1yA==", "bundleDependencies": [ "@napi-rs/wasm-runtime", "@emnapi/core", @@ -579,13 +609,14 @@ "cpu": [ "wasm32" ], + "dev": true, "license": "MIT", "optional": true, "dependencies": { - "@emnapi/core": "^1.8.1", - "@emnapi/runtime": "^1.8.1", - "@emnapi/wasi-threads": "^1.1.0", - "@napi-rs/wasm-runtime": "^1.1.1", + "@emnapi/core": "^1.10.0", + "@emnapi/runtime": "^1.10.0", + "@emnapi/wasi-threads": "^1.2.1", + "@napi-rs/wasm-runtime": "^1.1.4", "@tybys/wasm-util": "^0.10.1", "tslib": "^2.8.1" }, @@ -594,12 +625,13 @@ } }, "node_modules/@tailwindcss/oxide-win32-arm64-msvc": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-arm64-msvc/-/oxide-win32-arm64-msvc-4.2.4.tgz", - "integrity": "sha512-L9BXqxC4ToVgwMFqj3pmZRqyHEztulpUJzCxUtLjobMCzTPsGt1Fa9enKbOpY2iIyVtaHNeNvAK8ERP/64sqGQ==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-arm64-msvc/-/oxide-win32-arm64-msvc-4.3.0.tgz", + "integrity": "sha512-Pe+RPVTi1T+qymuuRpcdvwSVZjnll/f7n8gBxMMh3xLTctMDKqpdfGimbMyioqtLhUYZxdJ9wGNhV7MKHvgZsQ==", "cpu": [ "arm64" ], + "dev": true, "license": "MIT", "optional": true, "os": [ @@ -610,12 +642,13 @@ } }, "node_modules/@tailwindcss/oxide-win32-x64-msvc": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-x64-msvc/-/oxide-win32-x64-msvc-4.2.4.tgz", - "integrity": "sha512-ESlKG0EpVJQwRjXDDa9rLvhEAh0mhP1sF7sap9dNZT0yyl9SAG6T7gdP09EH0vIv0UNTlo6jPWyujD6559fZvw==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-x64-msvc/-/oxide-win32-x64-msvc-4.3.0.tgz", + "integrity": "sha512-Mvrf2kXW/yeW/OTezZlCGOirXRcUuLIBx/5Y12BaPM7wJoryG6dfS/NJL8aBPqtTEx/Vm4T4vKzFUcKDT+TKUA==", "cpu": [ "x64" ], + "dev": true, "license": "MIT", "optional": true, "os": [ @@ -626,14 +659,15 @@ } }, "node_modules/@tailwindcss/vite": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@tailwindcss/vite/-/vite-4.2.4.tgz", - "integrity": "sha512-pCvohwOCspk3ZFn6eJzrrX3g4n2JY73H6MmYC87XfGPyTty4YsCjYTMArRZm/zOI8dIt3+EcrLHAFPe5A4bgtw==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@tailwindcss/vite/-/vite-4.3.0.tgz", + "integrity": "sha512-t6J3OrB5Fc0ExuhohouH0fWUGMYL6PTLhW+E7zIk/pdbnJARZDCwjBznFnkh5ynRnIRSI4YjtTH0t6USjJISrw==", + "dev": true, "license": "MIT", "dependencies": { - "@tailwindcss/node": "4.2.4", - "@tailwindcss/oxide": "4.2.4", - "tailwindcss": "4.2.4" + "@tailwindcss/node": "4.3.0", + "@tailwindcss/oxide": "4.3.0", + "tailwindcss": "4.3.0" }, "peerDependencies": { "vite": "^5.2.0 || ^6 || ^7 || ^8" @@ -858,6 +892,16 @@ "url": "https://github.com/open-cli-tools/concurrently?sponsor=1" } }, + "node_modules/daisyui": { + "version": "5.5.19", + "resolved": "https://registry.npmjs.org/daisyui/-/daisyui-5.5.19.tgz", + "integrity": "sha512-pbFAkl1VCEh/MPCeclKL61I/MqRIFFhNU7yiXoDDRapXN4/qNCoMxeCCswyxEEhqL5eiTTfwHvucFtOE71C9sA==", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/saadeghi/daisyui?sponsor=1" + } + }, "node_modules/detect-libc": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz", @@ -880,9 +924,10 @@ "license": "MIT" }, "node_modules/enhanced-resolve": { - "version": "5.21.0", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.21.0.tgz", - "integrity": "sha512-otxSQPw4lkOZWkHpB3zaEQs6gWYEsmX4xQF68ElXC/TWvGxGMSGOvoNbaLXm6/cS/fSfHtsEdw90y20PCd+sCA==", + "version": "5.21.3", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.21.3.tgz", + "integrity": "sha512-QyL119InA+XXEkNLNTPCXPugSvOfhwv0JOlGNzvxs0hZaiHLNvXSpudUWsOlsXGWJh8G6ckCScEkVHfX3kw/2Q==", + "dev": true, "license": "MIT", "dependencies": { "graceful-fs": "^4.2.4", @@ -958,6 +1003,7 @@ "version": "4.2.11", "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", + "dev": true, "license": "ISC" }, "node_modules/has-flag": { @@ -982,6 +1028,7 @@ "version": "2.7.0", "resolved": "https://registry.npmjs.org/jiti/-/jiti-2.7.0.tgz", "integrity": "sha512-AC/7JofJvZGrrneWNaEnJeOLUx+JlGt7tNa0wZiRPT4MY1wmfKjt2+6O2p2uz2+skll8OZZmJMNqeke7kKbNgQ==", + "devOptional": true, "license": "MIT", "bin": { "jiti": "lib/jiti-cli.mjs" @@ -1266,6 +1313,7 @@ "version": "0.30.21", "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.21.tgz", "integrity": "sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ==", + "dev": true, "license": "MIT", "dependencies": { "@jridgewell/sourcemap-codec": "^1.5.5" @@ -1461,15 +1509,17 @@ } }, "node_modules/tailwindcss": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-4.2.4.tgz", - "integrity": "sha512-HhKppgO81FQof5m6TEnuBWCZGgfRAWbaeOaGT00KOy/Pf/j6oUihdvBpA7ltCeAvZpFhW3j0PTclkxsd4IXYDA==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-4.3.0.tgz", + "integrity": "sha512-y6nxMGB1nMW9R6k96e5gdIFzcfL/gTJRNaqGes1YvkLnPVXzWgbqFF2yLC0T8G774n24cx3Pe8XrKoniCOAH+Q==", + "dev": true, "license": "MIT" }, "node_modules/tapable": { "version": "2.3.3", "resolved": "https://registry.npmjs.org/tapable/-/tapable-2.3.3.tgz", "integrity": "sha512-uxc/zpqFg6x7C8vOE7lh6Lbda8eEL9zmVm/PLeTPBRhh1xCgdWaQ+J1CUieGpIfm2HdtsUpRv+HshiasBMcc6A==", + "dev": true, "license": "MIT", "engines": { "node": ">=6" diff --git a/package.json b/package.json index ce5f378..7abf6dd 100644 --- a/package.json +++ b/package.json @@ -7,16 +7,19 @@ "dev": "vite" }, "dependencies": { - "@tailwindcss/vite": "^4.1.11", "autoprefixer": "^10.4.20", "concurrently": "^9.0.1", "laravel-vite-plugin": "^3.1", - "tailwindcss": "^4.0.7", "vite": "^8.0.0" }, "optionalDependencies": { "@rollup/rollup-linux-x64-gnu": "4.9.5", "@tailwindcss/oxide-linux-x64-gnu": "^4.0.1", "lightningcss-linux-x64-gnu": "^1.29.1" + }, + "devDependencies": { + "@tailwindcss/vite": "^4.3.0", + "daisyui": "^5.5.19", + "tailwindcss": "^4.3.0" } } diff --git a/resources/css/app.css b/resources/css/app.css index ad6eeed..195d05c 100644 --- a/resources/css/app.css +++ b/resources/css/app.css @@ -52,7 +52,7 @@ [data-flux-field]:not(ui-radio, ui-checkbox) { } [data-flux-label] { - @apply !mb-0 !leading-tight; + @apply !mb-0 !leading-tight; } input:focus[data-flux-control], @@ -64,3 +64,69 @@ select:focus[data-flux-control] { /* \[:where(&)\]:size-4 { @apply size-4; } */ + + +/** + The lines above are intact. + The lines below were added by maryUI installer. +*/ + +/** daisyUI */ +@plugin "daisyui" { + themes: light --default +} + +@plugin "daisyui/theme" { + name: "light"; + default: true; + prefersdark: false; + color-scheme: "light"; + --color-base-100: oklch(100% 0 0); + --color-base-200: oklch(98% 0 0); + --color-base-300: oklch(95% 0 0); + --color-base-content: oklch(21% 0.006 285.885); + --color-primary: oklch(54% 0.245 262.881); + --color-primary-content: oklch(97% 0.014 254.604); + --color-secondary: oklch(65% 0.241 354.308); + --color-secondary-content: oklch(94% 0.028 342.258); + --color-accent: oklch(77% 0.152 181.912); + --color-accent-content: oklch(38% 0.063 188.416); + --color-neutral: oklch(14% 0.005 285.823); + --color-neutral-content: oklch(92% 0.004 286.32); + --color-info: oklch(74% 0.16 232.661); + --color-info-content: oklch(29% 0.066 243.157); + --color-success: oklch(76% 0.177 163.223); + --color-success-content: oklch(37% 0.077 168.94); + --color-warning: oklch(82% 0.189 84.429); + --color-warning-content: oklch(41% 0.112 45.904); + --color-error: oklch(71% 0.194 13.428); + --color-error-content: oklch(27% 0.105 12.094); + --radius-selector: 0.5rem; + --radius-field: 0.5rem; + --radius-box: 1rem; + --size-selector: 0.25rem; + --size-field: 0.25rem; + --border: 1px; + --depth: 0; + --noise: 0; +} + + +/* maryUI */ +@source "../../vendor/robsontenorio/mary/src/View/Components/**/*.php"; + +/* Theme toggle */ +@custom-variant dark (&:where(.dark, .dark *)); + +/** +* Paginator - Traditional style +* Because Laravel defaults does not match well the design of daisyUI. +*/ + +.mary-table-pagination span[aria-current="page"] > span { + @apply bg-primary text-base-100 +} + +.mary-table-pagination button { + @apply cursor-pointer +} diff --git a/resources/views/components/dashboard/connected-apps/⚡all.blade.php b/resources/views/components/dashboard/connected-apps/⚡all.blade.php index 96ea1ca..9aaf122 100644 --- a/resources/views/components/dashboard/connected-apps/⚡all.blade.php +++ b/resources/views/components/dashboard/connected-apps/⚡all.blade.php @@ -1,57 +1,36 @@ connectedServices = ConnectedServiceData::collect([ - new ConnectedServiceData( - name: 'Microsoft Outlook', - icon: 'home', - type: ConnectionProtocolEnum::OIDC, - connectionService: 'Azure AD', - status: ConnectionStatusEnum::Connected - ), - new ConnectedServiceData( - name: 'Microsoft Teams', - icon: 'home', - type: ConnectionProtocolEnum::OIDC, - connectionService: 'Azure AD', - status: ConnectionStatusEnum::Pending - ), - new ConnectedServiceData( - name: 'Keka HR', - icon: 'home', - type: ConnectionProtocolEnum::SAML, - connectionService: 'KeKA', - status: ConnectionStatusEnum::Disconnected - ), - new ConnectedServiceData( - name: 'Trutimer', - icon: 'home', - type: ConnectionProtocolEnum::SAML, - connectionService: 'Redmine', - status: ConnectionStatusEnum::Error - ), - ], DataCollection::class); + $this->connectedApps = $this->getConnectedApps(); + } + + #[Computed] + private function getConnectedApps() + { + $service = app(ConnectedAppService::class); + return $service->getAll(); } }; ?>
- @foreach ($connectedServices as $service) - + @foreach ($connectedApps as $app) +
@@ -61,8 +40,8 @@ public function mount(): void
-

{{$service->name}}

-

{{$service->type->name}} - {{$service->connectionService}}

+

{{$app->name}}

+

{{$app->protocol->name}} - {{$app->provider}}

@@ -70,13 +49,13 @@ public function mount(): void
$service->status === ConnectionStatusEnum::Connected, - 'bg-gray-400' => $service->status === ConnectionStatusEnum::Disconnected, - 'bg-yellow-400' => $service->status === ConnectionStatusEnum::Pending, - 'bg-red-400' => $service->status === ConnectionStatusEnum::Error, + 'bg-green-400' => $app->status === ConnectionStatusEnum::Connected, + 'bg-gray-400' => $app->status === ConnectionStatusEnum::Disconnected, + 'bg-yellow-400' => $app->status === ConnectionStatusEnum::Pending, + 'bg-red-400' => $app->status === ConnectionStatusEnum::Error, ]) >
-

{{ucfirst($service->status->name)}}

+

{{ucfirst($app->status->name)}}

Revoke
diff --git a/resources/views/components/dashboard/connected-apps/⚡connected-apps.blade.php b/resources/views/components/dashboard/connected-apps/⚡connected-apps.blade.php index 9dba34a..f81059e 100644 --- a/resources/views/components/dashboard/connected-apps/⚡connected-apps.blade.php +++ b/resources/views/components/dashboard/connected-apps/⚡connected-apps.blade.php @@ -8,25 +8,26 @@ ?>
- +
- {{ __('Add service') }} + {{ __('Connect App') }}
- - + + - - + +
Tricks
-
- + +
Musics
-
-
+ +
diff --git a/resources/views/layouts/app/sidebar.blade.php b/resources/views/layouts/app/sidebar.blade.php index 750990f..0fc30e8 100644 --- a/resources/views/layouts/app/sidebar.blade.php +++ b/resources/views/layouts/app/sidebar.blade.php @@ -14,6 +14,7 @@ {{ $slot }} + @livewireScripts diff --git a/resources/views/pages/connected-apps/⚡create.blade.php b/resources/views/pages/connected-apps/⚡create.blade.php index f15bdef..07f7b49 100644 --- a/resources/views/pages/connected-apps/⚡create.blade.php +++ b/resources/views/pages/connected-apps/⚡create.blade.php @@ -13,11 +13,13 @@ use Livewire\Attributes\Computed; use Livewire\Component; use Livewire\Attributes\Title; +use Mary\Traits\Toast; use Spatie\LaravelData\DataCollection; new #[Title('Create a service')] class extends Component { + use Toast; public StoreConnectedAppFrom $form; @@ -65,7 +67,10 @@ public function save() { try { $this->form->save(); + $this->success('New App connected '); + return to_route('dashboard'); } catch (Throwable $e) { + $this->error('Something gone wrong. Try again'); \Illuminate\Support\Facades\Log::error('Error while submitting Create a connected app', [$e->getMessage()]); } }