Skip to content

Commit 1031090

Browse files
committed
wip
1 parent 523d6a5 commit 1031090

File tree

2 files changed

+5
-171
lines changed

2 files changed

+5
-171
lines changed

content/plugins/mwguerra-file-manager.md

Lines changed: 5 additions & 171 deletions
Original file line numberDiff line numberDiff line change
@@ -2,179 +2,13 @@
22
name: File Manager
33
slug: mwguerra-file-manager
44
author_slug: mwguerra
5-
categories:
6-
- panel-builder
7-
- form-field
5+
categories: [panel-builder, form-field]
86
description: A file manager package for organizing files and browsing storage with dual operating modes, S3/MinIO support, file previews, and drag-and-drop uploads.
7+
discord_url:
98
docs_url: https://raw.githubusercontent.com/mwguerra/filemanager/main/README.md
109
github_repository: mwguerra/filemanager
1110
has_dark_theme: true
1211
has_translations: true
13-
versions:
14-
- 4
15-
publish_date: 2025-12-01
16-
---
17-
18-
A full-featured file manager package for Laravel and Filament v4 with dual operating modes, S3/MinIO support, file previews, and drag-and-drop uploads.
19-
20-
![File Manager - List View](https://raw.githubusercontent.com/mwguerra/filemanager/main/docs/images/File%20Manager%20-%20List%20View.png)
21-
22-
## Features
23-
24-
- **Dual operating modes**: Database mode (tracked files with metadata) or Storage mode (direct filesystem browsing)
25-
- **File browser**: Grid and list views, folder tree sidebar, breadcrumb navigation
26-
- **File operations**: Upload, move, rename, delete with drag-and-drop support
27-
- **Multi-selection**: Select multiple files with Ctrl/Cmd + click
28-
- **File previews**: Built-in viewers for video, audio, images, PDF, and text files
29-
- **Storage drivers**: Works with local, S3, MinIO, or any Laravel Storage driver
30-
- **Security**: MIME validation, blocked extensions, filename sanitization, signed URLs
31-
- **Authorization**: Configurable permissions with Laravel Policy support
32-
- **Embeddable**: Use as standalone pages or embed in Filament forms
33-
- **Dark mode**: Full dark mode support via Filament
34-
35-
## Installation
36-
37-
```bash
38-
composer require mwguerra/filemanager
39-
```
40-
41-
Publish configuration:
42-
43-
```bash
44-
php artisan vendor:publish --tag=filemanager-config
45-
```
46-
47-
Run migrations:
48-
49-
```bash
50-
php artisan migrate
51-
```
52-
53-
Run the install command:
54-
55-
```bash
56-
php artisan filemanager:install
57-
```
58-
59-
Register the plugin in your Panel Provider:
60-
61-
```php
62-
use MWGuerra\FileManager\FileManagerPlugin;
63-
64-
public function panel(Panel $panel): Panel
65-
{
66-
return $panel
67-
->plugins([
68-
FileManagerPlugin::make(),
69-
]);
70-
}
71-
```
72-
73-
## Plugin Configuration
74-
75-
Register all components or select only the ones you need:
76-
77-
```php
78-
use MWGuerra\FileManager\FileManagerPlugin;
79-
use MWGuerra\FileManager\Filament\Pages\FileManager;
80-
use MWGuerra\FileManager\Filament\Pages\FileSystem;
81-
use MWGuerra\FileManager\Filament\Pages\SchemaExample;
82-
use MWGuerra\FileManager\Filament\Resources\FileSystemItemResource;
83-
84-
// Register all enabled components (default)
85-
FileManagerPlugin::make()
86-
87-
// Register only specific components
88-
FileManagerPlugin::make([
89-
FileManager::class, // Database mode - full CRUD file manager
90-
FileSystem::class, // Storage mode - read-only file browser
91-
FileSystemItemResource::class, // Resource for direct database table editing
92-
SchemaExample::class, // Demo page showing embed components usage
93-
])
94-
95-
// Using the fluent API
96-
FileManagerPlugin::make()
97-
->only([
98-
FileManager::class,
99-
FileSystem::class,
100-
])
101-
```
102-
103-
| Component | URL | Description |
104-
|-----------|-----|-------------|
105-
| `FileManager::class` | `/admin/file-manager` | Database mode with full CRUD operations |
106-
| `FileSystem::class` | `/admin/file-system` | Storage mode for browsing files (read-only) |
107-
| `FileSystemItemResource::class` | `/admin/file-system-items` | Direct database table management |
108-
| `SchemaExample::class` | `/admin/schema-example` | Demo page for embedding components in forms |
109-
110-
## Quick Start
111-
112-
After installation, access the file manager at:
113-
114-
| Page | URL | Description |
115-
|------|-----|-------------|
116-
| File Manager | `/admin/file-manager` | Database mode with full CRUD operations |
117-
| File System | `/admin/file-system` | Storage mode for browsing files (read-only) |
118-
119-
### File Manager (Database Mode)
120-
121-
Full CRUD file management with metadata tracking, thumbnails, and folder organization.
122-
123-
![File Manager - Database Mode](https://raw.githubusercontent.com/mwguerra/filemanager/main/docs/images/File%20Manager%20Page%20-%20List%20View.png)
124-
125-
### File System (Storage Mode: Read-only)
126-
127-
Read-only file browser for direct filesystem access with S3/MinIO support.
128-
129-
![File System - Storage Mode](https://raw.githubusercontent.com/mwguerra/filemanager/main/docs/images/File%20System%20Page%20%28Storage%20Mode%29.png)
130-
131-
### FileSystemItems Resource
132-
133-
Direct database table management for file system items with Filament's standard resource interface.
134-
135-
![FileSystemItems Resource Page](https://raw.githubusercontent.com/mwguerra/filemanager/main/docs/images/FileSystemItems%20Resource%20Page.png)
136-
137-
## File Previews
138-
139-
Built-in viewers for common file types with modal preview support.
140-
141-
### Image Preview
142-
143-
![Image Preview](https://raw.githubusercontent.com/mwguerra/filemanager/main/docs/images/Schema%20Example%20Page%20-%20Image%20Preview.png)
144-
145-
### Video Preview
146-
147-
![Video Preview](https://raw.githubusercontent.com/mwguerra/filemanager/main/docs/images/Schema%20Example%20Page%20-%20Video%20Preview.png)
148-
149-
## Embedding in Forms
150-
151-
The package provides two embeddable schema components that can be added to any Filament form. Use `FileManagerEmbed` for full CRUD operations with database-tracked files, or `FileSystemEmbed` for a read-only storage browser. Both components are fully customizable with options for height, disk, target directory, and initial folder.
152-
153-
![File System Embed - Storage Mode](https://raw.githubusercontent.com/mwguerra/filemanager/main/docs/images/File%20System%20%28Storage%20Mode%29%20-%20Minio%20Disk.png)
154-
155-
```php
156-
use MWGuerra\FileManager\Schemas\Components\FileManagerEmbed;
157-
use MWGuerra\FileManager\Schemas\Components\FileSystemEmbed;
158-
159-
// Database mode (full CRUD)
160-
FileManagerEmbed::make()
161-
->height('400px')
162-
->disk('s3')
163-
->target('uploads'),
164-
165-
// Storage mode (read-only browser)
166-
FileSystemEmbed::make()
167-
->height('400px')
168-
->disk('public')
169-
->target('media'),
170-
```
171-
172-
## Issues and Contributing
173-
174-
Found a bug or have a feature request? Please open an issue on [GitHub Issues](https://github.com/mwguerra/filemanager/issues).
175-
176-
We welcome contributions! Please read our [Contributing Guide](https://github.com/mwguerra/filemanager/blob/main/CONTRIBUTING.md) before submitting a pull request.
177-
178-
## License
179-
180-
File Manager is open-sourced software licensed under the [MIT License](https://github.com/mwguerra/filemanager/blob/main/LICENSE).
12+
versions: [4]
13+
publish_date: 2025-12-07
14+
---
11.2 KB
Loading

0 commit comments

Comments
 (0)