added icon sharp feature
This commit is contained in:
parent
c4bbad2c7e
commit
2534d28dca
@ -19,6 +19,9 @@ class Icon extends Component
|
||||
/** @var bool */
|
||||
public $rounded;
|
||||
|
||||
/** @var bool */
|
||||
public $sharp;
|
||||
|
||||
/** @var bool */
|
||||
public $simpleIcons;
|
||||
|
||||
@ -35,13 +38,14 @@ class Icon extends Component
|
||||
*/
|
||||
public function __construct(
|
||||
string $icon = '', string $class = '',
|
||||
bool $filled = false, bool $rounded = false,
|
||||
bool $filled = false, bool $rounded = false, bool $sharp = false,
|
||||
bool $simpleIcons = false, bool $custom = false, string $alias = ''
|
||||
) {
|
||||
$this->icon = $icon;
|
||||
$this->class = ($simpleIcons) ? 'w-8 h-8 ' . $class : $class;
|
||||
$this->filled = $filled;
|
||||
$this->rounded = $rounded;
|
||||
$this->sharp = $sharp;
|
||||
$this->simpleIcons = $simpleIcons;
|
||||
$this->custom = $custom;
|
||||
$this->alias = $alias;
|
||||
|
@ -9,10 +9,11 @@
|
||||
@else
|
||||
<span
|
||||
@class([
|
||||
'material-icons-outlined' => (! $filled && ! $rounded),
|
||||
'material-icons-outlined' => (! $filled && ! $rounded && ! $sharp),
|
||||
$class,
|
||||
'material-icons' => $filled,
|
||||
'material-icons-round' => $rounded,
|
||||
'material-icons-sharp'=> $sharp,
|
||||
])
|
||||
{{ $attributes }}
|
||||
>{{ $icon }}</span>
|
||||
|
Loading…
x
Reference in New Issue
Block a user