Skip to content

Instantly share code, notes, and snippets.

@michaeldoye
Created September 17, 2018 12:25
Show Gist options
  • Save michaeldoye/f555c27036cdcf365fa42e2389d4c0f2 to your computer and use it in GitHub Desktop.
Save michaeldoye/f555c27036cdcf365fa42e2389d4c0f2 to your computer and use it in GitHub Desktop.
<mpb-component (click)="someFunc()" [options]="spinnerButtonOptions"></mpb-component>
spinnerButtonOptions = {
active: false,
text: 'Stroked Button',
spinnerSize: 19,
raised: false,
stroked: true,
buttonColor: 'accent',
spinnerColor: 'accent',
fullWidth: false,
disabled: false,
mode: 'indeterminate',
};
someFunc(): void {
this.spinnerButtonOptions.active = true;
setTimeout(() => {
this.spinnerButtonOptions.active = false;
}, 3350);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment