30 lines
620 B
Handlebars
30 lines
620 B
Handlebars
<button
|
|
disabled={{this.disabled}}
|
|
type={{this.type}}
|
|
class="
|
|
inline-flex
|
|
items-center
|
|
px-3
|
|
py-2
|
|
cursor-pointer
|
|
border
|
|
border-gray
|
|
bg-white
|
|
{{if @group "first:rounded-l-md last:rounded-r-md" "rounded-md"}}
|
|
text-gray-700
|
|
hover:bg-gray-50
|
|
focus:outline-none
|
|
{{if this.isActive "bg-gray-50"}}
|
|
"
|
|
{{on "click" this.handleClick}}
|
|
...attributes
|
|
>
|
|
{{#if this.isPending}}
|
|
<MdIcon::Loading @spin={{true}} class="mx-1"/>
|
|
{{else if @icon}}
|
|
<@icon class="mx-1"/>
|
|
{{/if}}
|
|
{{#if this.text}}
|
|
<span class="mx-1">{{this.text}}</span>
|
|
{{/if}}
|
|
</button>
|