PHPackages                             bugo/moonshine-title-with-slug - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Framework](/categories/framework)
4. /
5. bugo/moonshine-title-with-slug

ActiveLibrary[Framework](/categories/framework)

bugo/moonshine-title-with-slug
==============================

Title + slug field for MoonShine with auto-slug generation, live permalink preview, and inline editing.

0.1(1mo ago)00MITPHPPHP ^8.2CI passing

Since Apr 22Pushed 1mo agoCompare

[ Source](https://github.com/dragomano/moonshine-title-with-slug)[ Packagist](https://packagist.org/packages/bugo/moonshine-title-with-slug)[ Docs](https://github.com/dragomano/moonshine-title-with-slug)[ RSS](/packages/bugo-moonshine-title-with-slug/feed)WikiDiscussions main Synced 1w ago

READMEChangelog (1)Dependencies (6)Versions (2)Used By (0)

MoonShine Title With Slug
=========================

[](#moonshine-title-with-slug)

[![PHP](https://camo.githubusercontent.com/7bffcab80be9e1d83d7ec1e72f01342ea9ea17a26347f9b34a8d4a5ae8b58c48/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d253545382e322d626c75652e7376673f7374796c653d666c6174)](https://camo.githubusercontent.com/7bffcab80be9e1d83d7ec1e72f01342ea9ea17a26347f9b34a8d4a5ae8b58c48/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d253545382e322d626c75652e7376673f7374796c653d666c6174)[![Coverage Status](https://camo.githubusercontent.com/9909b66a0af8c462417051187953641cd38d16c5d3016c918211b24819c62144/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f647261676f6d616e6f2f6d6f6f6e7368696e652d7469746c652d776974682d736c75672f62616467652e7376673f6272616e63683d6d61696e)](https://coveralls.io/github/dragomano/moonshine-title-with-slug?branch=main)

[Русская версия](README.ru.md)

This package adds a title + permalink field group for MoonShine 4.

[![Preview](https://private-user-images.githubusercontent.com/229402/580561051-a34a900b-913d-40c6-9140-9d486372d2e1.png?jwt=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3ODA1MjE0MTYsIm5iZiI6MTc4MDUyMTExNiwicGF0aCI6Ii8yMjk0MDIvNTgwNTYxMDUxLWEzNGE5MDBiLTkxM2QtNDBjNi05MTQwLTlkNDg2MzcyZDJlMS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjYwNjAzJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI2MDYwM1QyMTExNTZaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0wZjM2N2EzZTIyZjEyYzVlOGU2M2JlYTM3ZTlhMzAzNmViZTM5NmFiMjhhOTlkODdiYzM5ZmNjNTE0OWViMGMzJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZyZXNwb25zZS1jb250ZW50LXR5cGU9aW1hZ2UlMkZwbmcifQ.oh5w0c2pqcqWY6ZD_J8ozhNOEe-vca9T_tC5Mb746dw)](https://private-user-images.githubusercontent.com/229402/580561051-a34a900b-913d-40c6-9140-9d486372d2e1.png?jwt=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3ODA1MjE0MTYsIm5iZiI6MTc4MDUyMTExNiwicGF0aCI6Ii8yMjk0MDIvNTgwNTYxMDUxLWEzNGE5MDBiLTkxM2QtNDBjNi05MTQwLTlkNDg2MzcyZDJlMS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjYwNjAzJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI2MDYwM1QyMTExNTZaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0wZjM2N2EzZTIyZjEyYzVlOGU2M2JlYTM3ZTlhMzAzNmViZTM5NmFiMjhhOTlkODdiYzM5ZmNjNTE0OWViMGMzJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZyZXNwb25zZS1jb250ZW50LXR5cGU9aW1hZ2UlMkZwbmcifQ.oh5w0c2pqcqWY6ZD_J8ozhNOEe-vca9T_tC5Mb746dw)Features
--------

[](#features)

- `TitleSlug::make(...)` helper for building a title + slug fieldset
- `Slug` field with permalink preview
- automatic slug generation from title
- manual slug editing with edit/reset/cancel controls
- auto-slug stops after manual slug editing
- create/edit context detection from the current model
- optional visit link with custom label or custom route URL
- configurable host/path visibility in permalink preview
- configurable title and slug labels
- configurable slug postfix
- custom slugifier callback
- `titleAfterStateUpdated` and `slugAfterStateUpdated` callbacks
- custom title field wrapper callback
- package config with default title field, slug field, and host
- translations and publishable assets/config

Installation
------------

[](#installation)

```
composer require bugo/moonshine-title-with-slug
```

Optionally publish config and assets:

```
php artisan vendor:publish --tag=moonshine-title-with-slug-config
php artisan vendor:publish --tag=moonshine-title-with-slug-assets
```

Basic usage
-----------

[](#basic-usage)

```
use Bugo\MoonShine\TitleWithSlug\TitleSlug;

TitleSlug::make(
    titleColumn: 'custom_title',
    slugColumn: 'custom_slug',
);
```

Example options
---------------

[](#example-options)

```
TitleSlug::make(
    titleColumn: 'custom_title',
    slugColumn: 'custom_slug',
)
    ->titleOptions(label: 'Title')
    ->slugOptions(
        label: 'Permalink',
        labelPostfix: '.html',
    )
    ->urlOptions(
        path: '/posts/',
        hostVisible: false,
        visitLinkLabel: 'Open',
    );
```

Validation
----------

[](#validation)

Use MoonShine page validation rules for server-side checks.

```
use Illuminate\Contracts\Validation\ValidationRule;
use Illuminate\Support\Stringable;
use Illuminate\Validation\Rule;
use MoonShine\Contracts\Core\TypeCasts\DataWrapperContract;

protected function rules(DataWrapperContract $item): array
{
    return [
        'title' => ['required'],
        'slug' => [
            'required',
            'regex:/^[a-z-]+$/',
            Rule::unique($item->getOriginal()::class, 'slug')
                ->ignoreModel($item->getOriginal()),
        ],
    ];
}
```

###  Health Score

34

—

LowBetter than 75% of packages

Maintenance90

Actively maintained with recent releases

Popularity0

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity36

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

49d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/6ef0dd570abdd5696bf5ba391bcd00ed0bb0ac5d1a5654785e8f204d548ddfc0?d=identicon)[Bugo](/maintainers/Bugo)

---

Top Contributors

[![dragomano](https://avatars.githubusercontent.com/u/229402?v=4)](https://github.com/dragomano "dragomano (2 commits)")

---

Tags

fieldsetmoonshineslugslugframeworklaravellivewirepermalinkmoonshine

###  Code Quality

TestsPest

Static AnalysisRector

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/bugo-moonshine-title-with-slug/health.svg)

```
[![Health](https://phpackages.com/badges/bugo-moonshine-title-with-slug/health.svg)](https://phpackages.com/packages/bugo-moonshine-title-with-slug)
```

###  Alternatives

[camya/filament-title-with-slug

TitleWithSlugInput - Easy Permalink Slugs for the FilamentPHP Form Builder (PHP / Laravel / Livewire)

13444.9k](/packages/camya-filament-title-with-slug)[laravel-lang/common

Easily connect the necessary language packs to the application

1563.6M32](/packages/laravel-lang-common)[blendbyte/filament-title-with-slug

Title + slug field for Filament v5 with auto-slug generation, live permalink preview, and inline editing.

1725.1k3](/packages/blendbyte-filament-title-with-slug)[ercogx/laravel-filament-starter-kit

This is a Filament v5 Starter Kit for Laravel 13, designed to accelerate the development of Filament-powered applications.

441.7k](/packages/ercogx-laravel-filament-starter-kit)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
