Skip to content

Media Library

This page is generated from public package documentation in capell-4/packages and the package manifest checked into the source repository.

FieldValue
Composer packagecapell-app/media-library
Package slugmedia-library
Product groupCapell Foundation
Tierfree
Bundlefoundation
Runtime contextsadmin
Capell version^4.0
Source repositorycapell-app/packages
Source pathpackages/media-library
Docs sourcepackages/media-library/docs
Manifestcapell.json

Media Library connects Capell to Awcodes Curator media, media health reporting, and Spatie Media migration support.

  • Package: capell-app/media-library
  • Namespace: Capell\MediaLibrary\
  • Surfaces: Filament admin, console, database
  • Capell dependencies: capell-app/admin, capell-app/core
  • Third-party dependencies: awcodes/filament-curator
  • Connects Capell to Curator media management, media health reporting, and Spatie Media migration support.
  • Gives editors a shared media surface for content, themes, and packages instead of isolated upload fields.
  • Gives developers a stable media integration point for rendering, health checks, and migrations.

Media Library connects Capell to Awcodes Curator media, media health reporting, and Spatie Media migration support.

  • Curator media model wrapper.
  • Media health admin page and table.
  • Curator media field factory.
  • Migration command and action for moving Spatie media into Curator.
  • InteractsWithCuratorMedia concern.

For developers: Centralises Curator integration behind actions, field factories, and model concerns so packages can use media fields consistently.

For teams: Helps site operators audit media records and move legacy media into the current Capell media foundation.

This package makes its Composer dependencies visible because they are part of the value proposition, not just plumbing. When an upstream package has a public repository, its linked preview card points readers back to the maintainers so their work gets proper credit.

Capell packages used here

Open-source packages used here

  • Awcodes Curator - the Filament media manager that Capell wraps for media fields, media health, and Curator-first media workflows.

Linked package previews

Awcodes Curator GitHub preview

Screenshots are generated from docs/screenshots.json during package deployment.

  • Media health page.
  • Media health table.
  • Curator media field inside a form.
  • Migration command output or report.
  • MediaLibraryServiceProvider registers the package.
  • Model: CuratorMedia.
  • Command: MigrateSpatieToCuratorCommand.
  • Action: MigrateSpatieMediaToCuratorAction.
  • Page: MediaHealthPage.
  • No migrations are present in this package.
AreaPathPurpose
Actionspackages/media-library/src/ActionsDomain operations. Test these directly where possible.
Datapackages/media-library/src/DataStructured payloads, form state, view models, and integration data.
Modelspackages/media-library/src/ModelsEloquent records owned by the package.
Filamentpackages/media-library/src/FilamentAdmin resources, pages, widgets, and settings UI.
Resourcespackages/media-library/resourcesViews, translations, assets, and package resources.
Testspackages/media-library/testsPackage-level Pest coverage.
  • Pages: MediaHealthPage, MediaHealthTable.
  • capell:media-migrate-to-curator {--dry-run : Report what would happen without writing} {--collection=* : Spatie collection names to migrate (repeatable; default: all)} {--owner-type= : Restrict migration to this owner model FQCN} {--chunk=200 : Number of Spatie media rows to process per chunk} (packages/media-library/src/Console/MigrateSpatieToCuratorCommand.php)
  • This package does not define its own migrations.

  • It relies on Curator and existing media tables.

  • Migration result data records counts and outcomes for Spatie-to-Curator moves.

  • Models: CuratorMedia.

  • Data objects live in src/Data/; use them for payloads, form state, and view models.

  • Adds Curator media field integration.
  • Adds media health admin page.
  • Adds migration command.
  • No package-owned database changes.
  • Install with composer require capell-app/media-library in the host Capell application.
  • In this repository, verify package changes with vendor/bin/pest; do not use php artisan.
  • MediaHealthPage (packages/media-library/src/Filament/Pages/MediaHealthPage.php, slug media-health)

  • Gate: MediaHealthPage: Filament Shield page permissions

  • Install and migrate Curator before relying on CuratorMedia.
  • Back up legacy Spatie media before migration.
  • Check disk paths and conversions before bulk migration.

Run package tests from the repository root:

Terminal window
vendor/bin/pest packages/media-library/tests --configuration=phpunit.xml
  • Put behaviour changes in src/Actions/; UI classes, commands, and controllers should call actions instead of owning domain logic.
  • Use package Data classes at boundaries instead of passing anonymous arrays between layers.