PHP code example of adelali / filament-cards-select
1. Go to this page and download the library: Download adelali/filament-cards-select library . Choose the download type require .
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
adelali / filament-cards-select example snippets
use Adelali\FilamentCardsSelect\Forms\Components\CardRadio;
CardRadio::make('plan')
->options([
'basic' => 'Basic Plan',
'pro' => 'Pro Plan',
'enterprise' => 'Enterprise Plan',
])
CardRadio::make('plan')
->options([
'basic' => 'Basic Plan',
'pro' => 'Pro Plan',
'enterprise' => 'Enterprise Plan',
])
->descriptions([
'basic' => 'Perfect for individuals getting started',
'pro' => 'For growing teams and businesses',
'enterprise' => 'Custom solutions for large organizations',
])
CardRadio::make('features')
->multiple()
->options([
'sso' => 'Single Sign-On',
'api' => 'API Access',
'support' => 'Priority Support',
])
CardRadio::make('features')
->checkboxList()
->options([...])
CardRadio::make('is_active')
->boolean('Active', 'Inactive')
CardRadio::make('plan')
->options([...])
->columns(2)
CardRadio::make('plan')
->options([...])
->columns([
'default' => 1,
'sm' => 2,
'md' => 3,
'lg' => 4,
])
CardRadio::make('plan')
->options([...])
->inline()
CardRadio::make('plan')
->options([
'basic' => 'Basic Plan',
'pro' => 'Pro Plan',
'enterprise' => 'Enterprise Plan',
])
->disableOptionWhen(fn (string $value): bool => $value === 'enterprise')