DEV: adds a loading property to d-button (#9072)

Usage:

```
{{d-button icon="times" label="foo.bar" isLoading=true}}
```

Note that  a button loading without an icon will shrink text size to prevent button to jump in size.

A button while loading is disabled.
This commit is contained in:
Joffrey JAFFEUX
2020-03-30 23:17:00 +02:00
committed by GitHub
parent 2a2555e598
commit 5b6cdd6fb5
5 changed files with 104 additions and 4 deletions

View File

@@ -198,7 +198,8 @@ module SvgSprite
"user-shield",
"user-times",
"users",
"wrench"
"wrench",
"spinner"
])
FA_ICON_MAP = { 'far fa-' => 'far-', 'fab fa-' => 'fab-', 'fas fa-' => '', 'fa-' => '' }