NgZzFx 8bit zounds for Angular ;)
Angular API for: ZzFX - Zuper Zmall Zound Zynth - Micro Edition
MIT License - Copyright 2019 Frank Force
In your component:
case1 = ;
Give your element a sound by adding the directive as follows:
In your template:
<div zoundfx trigger="click" [zound]="case1">💰</div>
Or by using the zzfs function wrapper:
playSound: ZzFxFn; case4 = ; ngOnInit onClick
API
Directive inputs:
- vol = 0.1; // Volume % should be a number from 0 to 1;
- trigger = 'onclick'; // String, a name of any event you want to react to
- zound: number[]; // See example Or custom your own sounds