From 9110cef1918e1eea3fd234c253c2cfc382a3e9f9 Mon Sep 17 00:00:00 2001 From: Ryan Scherler Date: Wed, 18 Mar 2020 17:35:26 -0700 Subject: [PATCH] Move to new repo --- README.md | 10 ++-- composer.json | 10 ++-- config/{alpine.php => filament.php} | 50 ++++++++--------- package.json | 2 +- resources/views/404.blade.php | 2 +- resources/views/auth/login.blade.php | 30 +++++----- .../views/auth/passwords/email.blade.php | 18 +++--- .../views/auth/passwords/reset.blade.php | 28 +++++----- resources/views/components/alert.blade.php | 2 +- resources/views/components/input.blade.php | 2 +- resources/views/dashboard.blade.php | 2 +- resources/views/layouts/admin.blade.php | 18 +++--- resources/views/layouts/app.blade.php | 2 +- resources/views/layouts/auth.blade.php | 4 +- .../views/livewire/user-edit-form.blade.php | 16 +++--- resources/views/livewire/users.blade.php | 6 +- resources/views/partials/links.blade.php | 8 +-- resources/views/partials/logo.blade.php | 2 +- resources/views/partials/nav.blade.php | 2 +- .../views/partials/user-actions.blade.php | 10 ++-- resources/views/users/edit.blade.php | 4 +- resources/views/users/index.blade.php | 4 +- routes/api.php | 2 +- routes/web.php | 6 +- src/Commands/CreateUserCommand.php | 12 ++-- src/Contracts/User.php | 2 +- src/{Alpine.php => Filament.php} | 16 +++--- src/{AlpineFacade.php => FilamentFacade.php} | 6 +- ...ovider.php => FilamentServiceProvider.php} | 56 +++++++++---------- src/Http/Components/Alert.php | 4 +- src/Http/Components/Button.php | 4 +- src/Http/Components/Checkbox.php | 4 +- src/Http/Components/Form.php | 4 +- src/Http/Components/Input.php | 4 +- src/Http/Components/InputGroup.php | 4 +- src/Http/Controllers/AssetController.php | 6 +- .../Auth/ForgotPasswordController.php | 6 +- src/Http/Controllers/Auth/LoginController.php | 14 ++--- .../Auth/ResetPasswordController.php | 8 +-- src/Http/Controllers/Controller.php | 4 +- src/Http/Controllers/DashboardController.php | 6 +- src/Http/Controllers/UserController.php | 12 ++-- src/Http/Livewire/UserAvatar.php | 4 +- src/Http/Livewire/UserEditForm.php | 4 +- src/Http/Livewire/Users.php | 6 +- src/Http/Middleware/Authenticate.php | 4 +- src/Notifications/ResetPassword.php | 4 +- src/Policies/UserPolicy.php | 2 +- src/Providers/AuthServiceProvider.php | 4 +- src/Support/BladeDirectives.php | 6 +- src/Support/ServiceProvider.php | 2 +- src/Traits/ConsoleValidation.php | 2 +- src/Traits/EventMap.php | 2 +- .../{AlpineUser.php => FilamentUser.php} | 8 +-- 54 files changed, 230 insertions(+), 230 deletions(-) rename config/{alpine.php => filament.php} (61%) rename src/{Alpine.php => Filament.php} (86%) rename src/{AlpineFacade.php => FilamentFacade.php} (57%) rename src/{AlpineServiceProvider.php => FilamentServiceProvider.php} (75%) rename src/Traits/{AlpineUser.php => FilamentUser.php} (89%) diff --git a/README.md b/README.md index 6ccfa2010a..e2c1035e7b 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# Alpine +# Filament A lightweight admin for your Laravel app. @@ -20,20 +20,20 @@ cd [appName] ### Install the package via composer ```bash -composer install madewithalpine/alpine # See note below +composer install filament/filament # See note below php artisan migrate ``` > ToDo: Add to Packagist (for now you will need to clone and [symlink the package](https://calebporzio.com/bash-alias-composer-link-use-local-folders-as-composer-dependancies)). -Add the necessary `Alpine\Traits\AlpineUser` trait to your `App\User` model. +Add the necessary `Filament\Traits\FilamentUser` trait to your `App\User` model. ### Create a user ```bash -php artisan alpine:user +php artisan filament:user ``` ## Upgrading -There are no special requirements for upgrading, other than `changing ^x.xx` version in your composer.json and running `composer update` as well as `php artisan migrate`. _Your app must meet the minimum requirements as well_. +There are no special requirements for upgrading, other than changing `^x.xx` version in your composer.json and running `composer update` as well as `php artisan migrate`. diff --git a/composer.json b/composer.json index cf889dc763..895771878c 100644 --- a/composer.json +++ b/composer.json @@ -1,5 +1,5 @@ { - "name": "madewithalpine/alpine", + "name": "filament/filament", "description": "A lightweight admin for your Laravel app.", "keywords": [ "laravel", @@ -8,7 +8,7 @@ "tailwindui", "alpine.js" ], - "homepage": "https://madewithalpine.com", + "homepage": "https://github.com/eastslopestudio/filament", "license": "MIT", "authors": [ { @@ -29,16 +29,16 @@ }, "autoload": { "psr-4": { - "Alpine\\": "src" + "Filament\\": "src" } }, "extra": { "laravel": { "providers": [ - "Alpine\\AlpineServiceProvider" + "Filament\\FilamentServiceProvider" ], "aliases": { - "Alpine": "Alpine\\AlpineFacade" + "Filament": "Filament\\FilamentFacade" } } }, diff --git a/config/alpine.php b/config/filament.php similarity index 61% rename from config/alpine.php rename to config/filament.php index 7bb1c5a4e5..22e2782825 100644 --- a/config/alpine.php +++ b/config/filament.php @@ -7,35 +7,35 @@ return [ | Name |-------------------------------------------------------------------------- | - | This is the name used by Alpine. + | This is the name used by Filament. | */ - 'name' => env('ALPINE_NAME', 'Alpine'), + 'name' => env('FILAMENT_NAME', 'Filament'), /* |-------------------------------------------------------------------------- | Base Route Prefix |-------------------------------------------------------------------------- | - | This is the URI path where Alpine will be accessible from. + | This is the URI path where Filament will be accessible from. | */ - 'path' => env('ALPINE_PATH_NAME', 'cp'), + 'path' => env('FILAMENT_PATH_NAME', 'cp'), /* |-------------------------------------------------------------------------- | Redirects |-------------------------------------------------------------------------- | - | This is the URI path where Alpine will be accessible from. + | This is the URI path where Filament will be accessible from. | */ 'redirects' => [ - 'admin' => 'alpine.admin.dashboard', // string or named route to redirect users when successfully authenticated. + 'admin' => 'filament.admin.dashboard', // string or named route to redirect users when successfully authenticated. ], @@ -44,7 +44,7 @@ return [ | Navigation |-------------------------------------------------------------------------- | - | Navigations used by Alpine. + | Navigations used by Filament. | */ @@ -53,22 +53,22 @@ return [ 'admin' => [ 'dashboard' => [ - 'label' => 'alpine::admin.dashboard', - 'icon' => 'heroicons/outline-md/md-home', // path to SVG icon using Alpine::svg() helper - 'url' => 'alpine.admin.dashboard', // string or named route - 'active' => 'alpine.admin.dashboard', // string or named route (may also be an array @link https://github.com/dwightwatson/active) + 'label' => 'filament::admin.dashboard', + 'icon' => 'heroicons/outline-md/md-home', // path to SVG icon using Filament::svg() helper + 'url' => 'filament.admin.dashboard', // string or named route + 'active' => 'filament.admin.dashboard', // string or named route (may also be an array @link https://github.com/dwightwatson/active) ], /* TODO 'Resources' => [ - 'label' => 'alpine::admin.resources', + 'label' => 'filament::admin.resources', 'icon' => 'heroicons/outline-md/md-collection', 'url' => '#', ], 'globals' => [ - 'label' => 'alpine::admin.globals', + 'label' => 'filament::admin.globals', 'icon' => 'heroicons/outline-md/md-globe', 'url' => '#', ], @@ -76,20 +76,20 @@ return [ */ 'users' => [ - 'label' => 'alpine::admin.users', + 'label' => 'filament::admin.users', 'icon' => 'heroicons/outline-md/md-user-group', - 'url' => 'alpine.admin.users.index', - 'active' => 'alpine.admin.users.*', + 'url' => 'filament.admin.users.index', + 'active' => 'filament.admin.users.*', 'ability' => 'view users', ], /* TODO 'Permissions' => [ - 'label' => 'alpine::admin.permissions', + 'label' => 'filament::admin.permissions', 'icon' => 'heroicons/outline-md/md-lock-closed', - 'url' => 'alpine.admin.permissions.index', - 'active' => 'alpine.admin.permissions.*', + 'url' => 'filament.admin.permissions.index', + 'active' => 'filament.admin.permissions.*', 'ability' => 'view permissions', ], @@ -104,12 +104,12 @@ return [ | Models |-------------------------------------------------------------------------- | - | The Eloquent Models used by Alpine. + | The Eloquent Models used by Filament. | */ 'models' => [ - // 'resource' => Alpine\Models\Resource::class, + // 'resource' => Filament\Models\Resource::class, ], /* @@ -117,7 +117,7 @@ return [ | Route Middleware |-------------------------------------------------------------------------- | - | These middleware will be attached to every route type in Alpine. + | These middleware will be attached to every route type in Filament. | */ @@ -135,12 +135,12 @@ return [ | Storage |-------------------------------------------------------------------------- | - | This is the storage disk Alpine will use to put file uploads, you may + | This is the storage disk Filament will use to put file uploads, you may | use any of the disks defined in the `config/filesystems.php`. | */ - 'storage_disk' => env('ALPINE_STORAGE_DISK', 'local'), - 'storage_path' => env('ALPINE_STORAGE_PATH', 'public/alpine'), + 'storage_disk' => env('FILAMENT_STORAGE_DISK', 'local'), + 'storage_path' => env('FILAMENT_STORAGE_PATH', 'public/filament'), ]; \ No newline at end of file diff --git a/package.json b/package.json index 582291736c..7964d1067f 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "alpine", + "name": "filament", "private": true, "scripts": { "dev": "npm run development", diff --git a/resources/views/404.blade.php b/resources/views/404.blade.php index 1dee0b747b..b177667869 100644 --- a/resources/views/404.blade.php +++ b/resources/views/404.blade.php @@ -1,4 +1,4 @@ -@extends('alpine::layouts.auth') +@extends('filament::layouts.auth') @section('title', $title) diff --git a/resources/views/auth/login.blade.php b/resources/views/auth/login.blade.php index dbf3f3bec9..a4c85287c3 100644 --- a/resources/views/auth/login.blade.php +++ b/resources/views/auth/login.blade.php @@ -1,30 +1,30 @@ -@extends('alpine::layouts.auth') +@extends('filament::layouts.auth') @section('title', $title) @section('main') - + - + - - - + + + - + - {{ __('Forgot Your Password?') }} + {{ __('Forgot Your Password?') }} - - + + - - - + + + - + - + @endsection \ No newline at end of file diff --git a/resources/views/auth/passwords/email.blade.php b/resources/views/auth/passwords/email.blade.php index dd0ce57dd6..900fd84954 100644 --- a/resources/views/auth/passwords/email.blade.php +++ b/resources/views/auth/passwords/email.blade.php @@ -1,23 +1,23 @@ -@extends('alpine::layouts.auth') +@extends('filament::layouts.auth') @section('title', $title) @section('main') - + - + - - - + + + - + - ← {{ __('Back to Login') }} + ← {{ __('Back to Login') }} - + @endsection \ No newline at end of file diff --git a/resources/views/auth/passwords/reset.blade.php b/resources/views/auth/passwords/reset.blade.php index a1810dfdb2..661e22064a 100644 --- a/resources/views/auth/passwords/reset.blade.php +++ b/resources/views/auth/passwords/reset.blade.php @@ -1,31 +1,31 @@ -@extends('alpine::layouts.auth') +@extends('filament::layouts.auth') @section('title', $title) @section('main') - + - - - + + + - - - + + + - - - + + + - + - ← {{ __('Back to Login') }} + ← {{ __('Back to Login') }} - + @endsection \ No newline at end of file diff --git a/resources/views/components/alert.blade.php b/resources/views/components/alert.blade.php index 4df4032e7b..956e508145 100644 --- a/resources/views/components/alert.blade.php +++ b/resources/views/components/alert.blade.php @@ -12,7 +12,7 @@ diff --git a/resources/views/components/input.blade.php b/resources/views/components/input.blade.php index e7d68b26b8..8dd74acd75 100644 --- a/resources/views/components/input.blade.php +++ b/resources/views/components/input.blade.php @@ -11,7 +11,7 @@ {{ $attributes }} /> @error($name)
- {{ Alpine::svg('heroicons/solid-sm/sm-exclamation-circle', 'h-5 w-5 text-red-500') }} + {{ Filament::svg('heroicons/solid-sm/sm-exclamation-circle', 'h-5 w-5 text-red-500') }}
@enderror diff --git a/resources/views/dashboard.blade.php b/resources/views/dashboard.blade.php index f445955630..4f72598512 100644 --- a/resources/views/dashboard.blade.php +++ b/resources/views/dashboard.blade.php @@ -1,4 +1,4 @@ -@extends('alpine::layouts.admin') +@extends('filament::layouts.admin') @section('title', $title) diff --git a/resources/views/layouts/admin.blade.php b/resources/views/layouts/admin.blade.php index c58cf6d122..d3ef333cd0 100644 --- a/resources/views/layouts/admin.blade.php +++ b/resources/views/layouts/admin.blade.php @@ -1,4 +1,4 @@ -@extends('alpine::layouts.app', ['classes' => ['body' => '']]) +@extends('filament::layouts.app', ['classes' => ['body' => '']]) @section('content')
@@ -8,20 +8,20 @@
- @include('alpine::partials.user-actions') + @include('filament::partials.user-actions')
@@ -30,15 +30,15 @@
- @include('alpine::partials.user-actions') + @include('filament::partials.user-actions')
@@ -46,7 +46,7 @@
diff --git a/resources/views/layouts/app.blade.php b/resources/views/layouts/app.blade.php index 5ada980bf3..b286b3788b 100644 --- a/resources/views/layouts/app.blade.php +++ b/resources/views/layouts/app.blade.php @@ -8,7 +8,7 @@ @yield('title') • {{ config('app.name') }} @livewireStyles - @alpineAssets + @filamentAssets @stack('head') - @include('alpine::partials.logo', ['classes' => 'mx-auto w-16 h-16 rounded-full']) + @include('filament::partials.logo', ['classes' => 'mx-auto w-16 h-16 rounded-full'])

@yield('title')

diff --git a/resources/views/livewire/user-edit-form.blade.php b/resources/views/livewire/user-edit-form.blade.php index c1ddf6747d..7c4b18b7c3 100644 --- a/resources/views/livewire/user-edit-form.blade.php +++ b/resources/views/livewire/user-edit-form.blade.php @@ -1,15 +1,15 @@
- + - - - + + + - - - + + + - + \ No newline at end of file diff --git a/resources/views/livewire/users.blade.php b/resources/views/livewire/users.blade.php index f9ad4665b7..941f895464 100644 --- a/resources/views/livewire/users.blade.php +++ b/resources/views/livewire/users.blade.php @@ -2,8 +2,8 @@ - {{ $users->links('alpine::partials.links') }} + {{ $users->links('filament::partials.links') }}
\ No newline at end of file diff --git a/resources/views/partials/links.blade.php b/resources/views/partials/links.blade.php index 9372b45ffa..157bc2ae09 100644 --- a/resources/views/partials/links.blade.php +++ b/resources/views/partials/links.blade.php @@ -3,12 +3,12 @@ {{-- Previous Page Link --}} @if ($paginator->onFirstPage())
  • - {{ Alpine::svg('heroicons/solid-sm/sm-cheveron-left', 'h-5 w-5') }} + {{ Filament::svg('heroicons/solid-sm/sm-cheveron-left', 'h-5 w-5') }}
  • @else
  • @endif @@ -44,12 +44,12 @@ @if ($paginator->hasMorePages())
  • @else
  • - {{ Alpine::svg('heroicons/solid-sm/sm-cheveron-right', 'h-5 w-5') }} + {{ Filament::svg('heroicons/solid-sm/sm-cheveron-right', 'h-5 w-5') }}
  • @endif diff --git a/resources/views/partials/logo.blade.php b/resources/views/partials/logo.blade.php index 36f2d852cd..c2c1bcdb97 100644 --- a/resources/views/partials/logo.blade.php +++ b/resources/views/partials/logo.blade.php @@ -1 +1 @@ -{{ Alpine::svg('logo', $classes ?? '') }} +{{ Filament::svg('logo', $classes ?? '') }} diff --git a/resources/views/partials/nav.blade.php b/resources/views/partials/nav.blade.php index 4e39fe70fd..ffdf0fcb62 100644 --- a/resources/views/partials/nav.blade.php +++ b/resources/views/partials/nav.blade.php @@ -11,7 +11,7 @@ @endisset > @if (isset($item['icon'])) - {{ Alpine::svg($item['icon'], 'mr-3 h-6 w-6 text-gray-400') }} + {{ Filament::svg($item['icon'], 'mr-3 h-6 w-6 text-gray-400') }} @endif {{ __($item['label']) }}
    diff --git a/resources/views/partials/user-actions.blade.php b/resources/views/partials/user-actions.blade.php index 16cf41df8d..be93a14a6a 100644 --- a/resources/views/partials/user-actions.blade.php +++ b/resources/views/partials/user-actions.blade.php @@ -1,6 +1,6 @@
    - +
    diff --git a/resources/views/users/edit.blade.php b/resources/views/users/edit.blade.php index 7ad6d23253..77b4a9204c 100644 --- a/resources/views/users/edit.blade.php +++ b/resources/views/users/edit.blade.php @@ -1,9 +1,9 @@ -@extends('alpine::layouts.admin') +@extends('filament::layouts.admin') @section('title', $title) @section('main')
    - @livewire('alpine::user-edit-form', ['user' => $user]) + @livewire('filament::user-edit-form', ['user' => $user])
    @endsection \ No newline at end of file diff --git a/resources/views/users/index.blade.php b/resources/views/users/index.blade.php index f575f064c7..288e9c9b1d 100644 --- a/resources/views/users/index.blade.php +++ b/resources/views/users/index.blade.php @@ -1,7 +1,7 @@ -@extends('alpine::layouts.admin') +@extends('filament::layouts.admin') @section('title', $title) @section('main') - @livewire('alpine::users') + @livewire('filament::users') @endsection \ No newline at end of file diff --git a/routes/api.php b/routes/api.php index fb009c67ec..574abd8340 100644 --- a/routes/api.php +++ b/routes/api.php @@ -15,7 +15,7 @@ use Illuminate\Http\Request; */ // protected routes... -Route::middleware('auth.alpine:api')->group(function () { +Route::middleware('auth.filament:api')->group(function () { // curl -H "Accept: application/json" -X GET http://localhost:8000/cp/api/user Route::get('/user', function (Request $request) { diff --git a/routes/web.php b/routes/web.php index 884ed33784..f8d555f3cd 100644 --- a/routes/web.php +++ b/routes/web.php @@ -16,8 +16,8 @@ use Illuminate\Support\Facades\Route; // asset routes... Route::name('assets.')->group(function () { - Route::get('alpine.css', 'AssetController@css')->name('css'); - Route::get('alpine.js', 'AssetController@js')->name('js'); + Route::get('filament.css', 'AssetController@css')->name('css'); + Route::get('filament.js', 'AssetController@js')->name('js'); }); @@ -38,7 +38,7 @@ Route::name('auth.')->namespace('Auth')->group(function () { }); // protected admin routes... -Route::name('admin.')->middleware('auth.alpine')->group(function () { +Route::name('admin.')->middleware('auth.filament')->group(function () { Route::get('/', 'DashboardController')->name('dashboard'); diff --git a/src/Commands/CreateUserCommand.php b/src/Commands/CreateUserCommand.php index 0d00e9b0b3..330073b8ec 100644 --- a/src/Commands/CreateUserCommand.php +++ b/src/Commands/CreateUserCommand.php @@ -1,10 +1,10 @@ $superAdmin, ]); - $appName = config('alpine.name'); - $loginURL = route('alpine.auth.login'); + $appName = config('filament.name'); + $loginURL = route('filament.auth.login'); $this->info("Success! You may now login to {$appName} ( {$loginURL} ) with user `{$user->name}`."); } } diff --git a/src/Contracts/User.php b/src/Contracts/User.php index 94c7a12a5d..504e5478b0 100644 --- a/src/Contracts/User.php +++ b/src/Contracts/User.php @@ -1,6 +1,6 @@ + - + - - + + '); } diff --git a/src/AlpineFacade.php b/src/FilamentFacade.php similarity index 57% rename from src/AlpineFacade.php rename to src/FilamentFacade.php index f4e7ecf7a6..ffbc5aae20 100644 --- a/src/AlpineFacade.php +++ b/src/FilamentFacade.php @@ -1,13 +1,13 @@ app->singleton('alpine', Alpine::class); + $this->app->singleton('filament', Filament::class); } /** @@ -69,9 +69,9 @@ class AlpineServiceProvider extends ServiceProvider */ protected function registerConfig() { - $this->mergeConfigFrom($this->packagePath.'config/alpine.php', 'alpine'); - if ($this->app['alpine']->handling()) { - // $this->mergeFromConfig('existing-package-config', $this->app['config']->get('alpine.existing-package-config', [])); + $this->mergeConfigFrom($this->packagePath.'config/filament.php', 'filament'); + if ($this->app['filament']->handling()) { + // $this->mergeFromConfig('existing-package-config', $this->app['config']->get('filament.existing-package-config', [])); } } @@ -83,7 +83,7 @@ class AlpineServiceProvider extends ServiceProvider protected function registerBindings() { $this->app->bind(UserContract::class, config('auth.providers.users.model')); - // $this->app->bind(ResourceContract::class, config('alpine.models.resource')); + // $this->app->bind(ResourceContract::class, config('filament.models.resource')); } /** @@ -134,7 +134,7 @@ class AlpineServiceProvider extends ServiceProvider */ protected function registerMiddleware() { - Route::aliasMiddleware('auth.alpine', Authenticate::class); + Route::aliasMiddleware('auth.filament', Authenticate::class); } /** @@ -144,17 +144,17 @@ class AlpineServiceProvider extends ServiceProvider */ protected function registerRoutes() { - $namespace = 'Alpine\Http\Controllers'; - $name = 'alpine.'; + $namespace = 'Filament\Http\Controllers'; + $name = 'filament.'; - Route::middleware(config('alpine.middleware.web')) - ->prefix(config('alpine.path')) + Route::middleware(config('filament.middleware.web')) + ->prefix(config('filament.path')) ->namespace($namespace) ->name($name) ->group($this->packagePath.'routes/web.php'); - Route::middleware(config('alpine.middleware.api')) - ->prefix(config('alpine.path').'/api') + Route::middleware(config('filament.middleware.api')) + ->prefix(config('filament.path').'/api') ->namespace($namespace) ->name($name) ->group($this->packagePath.'routes/api.php'); @@ -167,7 +167,7 @@ class AlpineServiceProvider extends ServiceProvider */ protected function registerResources() { - $this->loadViewsFrom($this->packagePath.'resources/views', 'alpine'); + $this->loadViewsFrom($this->packagePath.'resources/views', 'filament'); } /** @@ -177,7 +177,7 @@ class AlpineServiceProvider extends ServiceProvider */ protected function registerTranslations() { - $this->loadTranslationsFrom($this->packagePath.'resources/lang', 'alpine'); + $this->loadTranslationsFrom($this->packagePath.'resources/lang', 'filament'); } /** @@ -201,8 +201,8 @@ class AlpineServiceProvider extends ServiceProvider { if ($this->app->runningInConsole()) { $this->publishes([ - $this->packagePath.'config/alpine.php' => config_path('alpine.php'), - ], 'alpine-config'); + $this->packagePath.'config/filament.php' => config_path('filament.php'), + ], 'filament-config'); } } @@ -214,12 +214,12 @@ class AlpineServiceProvider extends ServiceProvider public function registerBlade() { // Register package directives - Blade::directive('alpineAssets', [BladeDirectives::class, 'alpineAssets']); + Blade::directive('filamentAssets', [BladeDirectives::class, 'filamentAssets']); // Automatically register package components foreach (File::glob(__DIR__.'/Http/Components/*.php') as $path) { $baseName = basename($path, '.php'); - Blade::component("\\Alpine\\Http\\Components\\{$baseName}", 'alpine-'.Str::of($baseName)->kebab()); + Blade::component("\\Filament\\Http\\Components\\{$baseName}", 'filament-'.Str::of($baseName)->kebab()); } } @@ -238,7 +238,7 @@ class AlpineServiceProvider extends ServiceProvider // Automatically register package components foreach (File::glob(__DIR__.'/Http/Livewire/*.php') as $path) { $baseName = basename($path, '.php'); - Livewire::component('alpine::'.Str::of($baseName)->kebab(), "\\Alpine\\Http\\Livewire\\{$baseName}"); + Livewire::component('filament::'.Str::of($baseName)->kebab(), "\\Filament\\Http\\Livewire\\{$baseName}"); } } } diff --git a/src/Http/Components/Alert.php b/src/Http/Components/Alert.php index d8ef094181..8286492393 100644 --- a/src/Http/Components/Alert.php +++ b/src/Http/Components/Alert.php @@ -1,6 +1,6 @@ redirectTo()); } - $title = __('alpine::auth.login', ['name' => config('app.name')]); + $title = __('filament::auth.login', ['name' => config('app.name')]); - return view('alpine::auth.login', compact('title')); + return view('filament::auth.login', compact('title')); } /** @@ -62,9 +62,9 @@ class LoginController extends Controller return $request->wantsJson() ? new Response('', 204) - : redirect(route('alpine.auth.login'))->with('alert', [ + : redirect(route('filament.auth.login'))->with('alert', [ 'type' => 'success', - 'message' => __('alpine::auth.logout'), + 'message' => __('filament::auth.logout'), ]); } } \ No newline at end of file diff --git a/src/Http/Controllers/Auth/ResetPasswordController.php b/src/Http/Controllers/Auth/ResetPasswordController.php index 6ed1037764..46c5039779 100644 --- a/src/Http/Controllers/Auth/ResetPasswordController.php +++ b/src/Http/Controllers/Auth/ResetPasswordController.php @@ -1,10 +1,10 @@ email; - return view('alpine::auth.passwords.reset', compact('title', 'email', 'token')); + return view('filament::auth.passwords.reset', compact('title', 'email', 'token')); } /** diff --git a/src/Http/Controllers/Controller.php b/src/Http/Controllers/Controller.php index d5ad2df99b..73cb7f9c20 100644 --- a/src/Http/Controllers/Controller.php +++ b/src/Http/Controllers/Controller.php @@ -1,6 +1,6 @@ authorize('view', app(UserContract::class)); - $title = __('alpine::admin.users'); + $title = __('filament::admin.users'); - return view('alpine::users.index', compact('title')); + return view('filament::users.index', compact('title')); } /** @@ -34,8 +34,8 @@ class UserController extends Controller $this->authorize('edit', $user); - $title = __('alpine::admin.user_edit', ['name' => $user->name]); + $title = __('filament::admin.user_edit', ['name' => $user->name]); - return view('alpine::users.edit', compact('title', 'user')); + return view('filament::users.edit', compact('title', 'user')); } } \ No newline at end of file diff --git a/src/Http/Livewire/UserAvatar.php b/src/Http/Livewire/UserAvatar.php index 8c9a1e109d..489727821c 100644 --- a/src/Http/Livewire/UserAvatar.php +++ b/src/Http/Livewire/UserAvatar.php @@ -1,6 +1,6 @@ $userModel::paginate(2), ]); } diff --git a/src/Http/Middleware/Authenticate.php b/src/Http/Middleware/Authenticate.php index 375ef3da86..2ec98a2825 100644 --- a/src/Http/Middleware/Authenticate.php +++ b/src/Http/Middleware/Authenticate.php @@ -1,6 +1,6 @@ expectsJson()) { - return route('alpine.auth.login'); + return route('filament.auth.login'); } } } diff --git a/src/Notifications/ResetPassword.php b/src/Notifications/ResetPassword.php index c1d971a7b7..63e7c7908e 100644 --- a/src/Notifications/ResetPassword.php +++ b/src/Notifications/ResetPassword.php @@ -1,6 +1,6 @@ token); } else { - $url = url(config('app.url').route('alpine.auth.password.reset', [ + $url = url(config('app.url').route('filament.auth.password.reset', [ 'token' => $this->token, 'email' => $notifiable->getEmailForPasswordReset(), ], false)); diff --git a/src/Policies/UserPolicy.php b/src/Policies/UserPolicy.php index 51790f6fa9..49e2a56385 100644 --- a/src/Policies/UserPolicy.php +++ b/src/Policies/UserPolicy.php @@ -1,6 +1,6 @@ mergeFillable(['is_super_admin', 'avatar']); $this->mergeCasts(['is_super_admin' => 'boolean']);