Skip to content

Commit

Permalink
feat: button is working modifier (#471)
Browse files Browse the repository at this point in the history
* feat: button is working modifier

* feat: adding loader param to button

* fix: only show spinner when type is button or submit
  • Loading branch information
NiclasNorin authored Oct 25, 2024
1 parent f4763be commit e837162
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion source/php/Component/Button/button.blade.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
<{{$componentElement}} class="{{ $class }}" target="{{ $target }}" {!! $attribute !!}>
@if(!$isLabel) <{{$labelElement}} class="{{$baseClass}}__label"> @endif

@if ($type === 'submit' || $type === 'button')
<span class="{{$baseClass}}__loader"></span>
@endif
@if($icon)
<span class="{{$baseClass}}__label-icon {{ $classListIcon }}">
@icon(['icon' => $icon, 'size' => $size, 'attributeList' => ['aria-hidden' => 'true']])
Expand Down

0 comments on commit e837162

Please sign in to comment.