spunkylm/better-boolean

A slightly more customizable boolean field for Laravel Nova

Maintainers

Package info

github.com/spunkylm/better-boolean

Issues

pkg:composer/spunkylm/better-boolean

Statistics

Installs: 6

Dependents: 0

Suggesters: 0

Stars: 0

dev-master 2019-07-12 13:29 UTC

This package is auto-updated.

Last update: 2026-03-13 04:27:31 UTC


README

A drop in replacement for the default Laravel Nova Boolean field

Installation

composer require spunkylm/better-boolean

Usage

The Toggle has all the same options as the Boolean field so you can set the values to be stored in the Model.

BetterBoolean::make('Status')
    ->trueValue(true, 'Good', '#21b978')
    ->falseValue(false, 'Neutral', '#bdbdbd')
    ->showLabelOnIndex(),