PHPackages                             anish/maskable-entry - 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. [Templating &amp; Views](/categories/templating)
4. /
5. anish/maskable-entry

ActiveLibrary[Templating &amp; Views](/categories/templating)

anish/maskable-entry
====================

A powerful Filament PHP infolist component that enables seamless maskable entry. Features include maskable entry, preview functionality, and easy integration with Laravel. Perfect for maskable values in infolists.

v1.0.3(5mo ago)12366↑38.5%4MITPHPPHP ^8.1

Since Nov 28Pushed 4mo agoCompare

[ Source](https://github.com/anishregmi17/filament-maskable-entry)[ Packagist](https://packagist.org/packages/anish/maskable-entry)[ Docs](https://github.com/anishregminaglibang/maskable-entry)[ GitHub Sponsors](https://github.com/sponsors/anishregminaglibang/)[ RSS](/packages/anish-maskable-entry/feed)WikiDiscussions main Synced today

READMEChangelog (4)Dependencies (2)Versions (7)Used By (0)

 Filament Maskable Entry
=========================

[](#-filament-maskable-entry-)

[![maskable-entry](https://private-user-images.githubusercontent.com/103883548/520223235-79a3ca44-e33e-4ea8-a843-805f68ae519d.jpg?jwt=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3ODA3MTgzNDQsIm5iZiI6MTc4MDcxODA0NCwicGF0aCI6Ii8xMDM4ODM1NDgvNTIwMjIzMjM1LTc5YTNjYTQ0LWUzM2UtNGVhOC1hODQzLTgwNWY2OGFlNTE5ZC5qcGc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjYwNjA2JTJGdXMtZWFzdC0xJTJGcz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0.Mv2JlyjL2JZdouWDLMuCnFuoap4_L_Bo-TXmzpnRClM)

**A reusable maskable entry component for Filament Infolists.**

A powerful Filament PHP infolist component that enables seamless maskable entry. Ideal for hiding and toggling sensitive values such as passwords, social security numbers, credit card numbers, and API keys.

---

Features
--------

[](#features)

- 🔒 **Maskable Display** — Hide sensitive data with custom mask patterns
- 👁️ **Toggle Visibility** — One click to reveal or hide the actual value
- 🎨 **Native Filament v4 &amp; v5 Integration** — Works like any infolist entry
- ⚙️ **Fully Configurable** — Custom patterns, masking characters, closures
- 📱 **Responsive** — Works across all device sizes

---

Requirements
------------

[](#requirements)

- PHP 8.1+
- Laravel 10+
- Filament 4.x or 5.x

---

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

[](#installation)

```
composer require anish/maskable-entry
```

The package auto-discovers its service provider—no manual setup required.

---

Basic Usage
-----------

[](#basic-usage)

```
use Anish\MaskableEntry\Components\MaskableEntry;
use Illuminate\Support\Facades\Auth;
use Filament\Schemas\Schema;

public static function configure(Schema $schema): Schema
{
    return $schema->components([
        MaskableEntry::make('social_security_number')
            ->maskValue('XXX-XX-XXXX')
            ->actualValue(fn ($record) => $record->social_security_number)
            ->toggleable(Auth::user()->can('view_social_security_number'))
            ->label('Social Security Number'),
    ]);
}
```

### Note:

[](#note)

If you are using a custom theme add the plugin's views to your theme css file or your app's css file.

```
@source '../../../../vendor/anish/maskable-entry/resources/views/**/*.blade.php

```

Advanced Usage
--------------

[](#advanced-usage)

### Custom Mask Pattern

[](#custom-mask-pattern)

```
MaskableEntry::make('credit_card')
    ->maskValue('XXXX-XXXX-XXXX-XXXX')
    ->actualValue(fn ($record) => $record->credit_card_number)
    ->label('Credit Card Number');
```

### Using a Closure for Actual Value

[](#using-a-closure-for-actual-value)

```
MaskableEntry::make('password')
    ->maskValue('XXXXXXXX')
    ->actualValue(fn (User $record) => $record->password)
    ->label('Password');
```

---

Available Methods
-----------------

[](#available-methods)

### `maskValue(string $value)`

[](#maskvaluestring-value)

The pattern shown in masked mode. Use `X` (or your custom char) to represent masked digits.

```
->maskValue('XXX-XX-XXXX')
```

### `actualValue(string|Closure|null $value)`

[](#actualvaluestringclosurenull-value)

Defines the value revealed on toggle.

```
->actualValue(fn ($record) => $record->social_security_number)
// or
->actualValue('123-45-6789')
```

### Supports All Standard `TextEntry` Methods

[](#supports-all-standard-textentry-methods)

```
MaskableEntry::make('field')
    ->maskValue('XXX-XX-XXXX')
    ->actualValue(fn ($record) => $record->value)
    ->label('Custom Label')
    ->placeholder('N/A')
    ->copyable()
    ->icon('heroicon-o-shield-check');
```

---

How It Works
------------

[](#how-it-works)

1. **Masked State** — Displays the mask pattern (`XXX-XX-XXXX`)
2. **Toggle Button** — Eye icon switches visibility
3. **Revealed State** — Shows the actual value formatted
4. **Formatting** — Automatically aligns characters to mask structure

---

Testing
-------

[](#testing)

```
composer test
```

---

Code Style
----------

[](#code-style)

This package uses Laravel Pint:

```
composer format
```

---

Contributing
------------

[](#contributing)

Contributions are welcome!

### Development Setup

[](#development-setup)

1. Clone the repo
2. `composer install`
3. Create a new branch
4. Write your feature
5. Run tests &amp; Pint
6. Submit PR

---

Security
--------

[](#security)

If you find a security issue, please email: ****

---

Changelog
---------

[](#changelog)

See **[CHANGELOG](CHANGELOG.md)**.

---

Credits
-------

[](#credits)

- [Anish Regmi](https://github.com/anishregmi17)
- All Contributors

---

License
-------

[](#license)

MIT

###  Health Score

42

—

FairBetter than 88% of packages

Maintenance73

Regular maintenance activity

Popularity25

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 94.7% 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

Every ~20 days

Total

4

Last Release

156d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/103883548?v=4)[Anish Regmi ](/maintainers/anishregmi17)[@anishregmi17](https://github.com/anishregmi17)

---

Top Contributors

[![anishregmi17](https://avatars.githubusercontent.com/u/103883548?v=4)](https://github.com/anishregmi17 "anishregmi17 (18 commits)")[![Shrimpstronaut](https://avatars.githubusercontent.com/u/3121039?v=4)](https://github.com/Shrimpstronaut "Shrimpstronaut (1 commits)")

---

Tags

laravellaravel-packagefilamentfilament-componentanishregminaglibangmaskable-entry

### Embed Badge

![Health badge](/badges/anish-maskable-entry/health.svg)

```
[![Health](https://phpackages.com/badges/anish-maskable-entry/health.svg)](https://phpackages.com/packages/anish-maskable-entry)
```

###  Alternatives

[rawilk/profile-filament-plugin

Profile &amp; MFA starter kit for filament.

3914.6k](/packages/rawilk-profile-filament-plugin)[ysfkaya/filament-phone-input

A phone input component for Laravel Filament

3161.3M24](/packages/ysfkaya-filament-phone-input)[stephenjude/filament-jetstream

A Laravel starter kit built with Filament inspired by Jetstream.

17760.2k3](/packages/stephenjude-filament-jetstream)[stephenjude/filament-two-factor-authentication

Filament Two Factor Authentication: Google 2FA + Passkey Authentication

84215.9k9](/packages/stephenjude-filament-two-factor-authentication)[relaticle/custom-fields

User Defined Custom Fields for Laravel Filament

16354.2k](/packages/relaticle-custom-fields)[croustibat/filament-jobs-monitor

Background Jobs monitoring like Horizon for all drivers for FilamentPHP

274325.8k8](/packages/croustibat-filament-jobs-monitor)

PHPackages © 2026

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