I have tried to implement a spinner within a button but for some reason the spinner seems to be top aligned instead of vertically centered:
My code is the following:
<button type="submit" class="button button-block button-positive">
<ion-spinner class="spinner-energized"></ion-spinner> Click me!
</button>
Codepen: http://codepen.io/anon/pen/BjOqvK?editors=1010
Any idea why?
The Ionic team offered the following solution:
.spinner svg {
width: 16px !important;
height: 16px !important;
}
New codepen
They gave me a bit more context:
This was not the intended use for ion-spinner, so custom css is needed. You need to adjust the width/height.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With