evan-007 / react-guitar-chords

Simple react component for guitar chord charts with audio
MIT License
21 stars 3 forks source link

Better strumming #12

Open surikov opened 6 years ago

surikov commented 6 years ago

See https://surikov.github.io/midi-sounds-react-examples/examples/midi-sounds-example8/build/ for guitar strumming Source for React https://www.npmjs.com/package/midi-sounds-react

evan-007 commented 6 years ago

hi @surikov, thanks for your work on midi-sounds! I had originally tried to use the react component, but couldn't find a way to hide the Midi Sounds svg that triggers the synth modal, so I ended up implementing just the audio here. Would you want a PR that adds a prop to hide the logo? Or is there another way to do it that I missed?

surikov commented 6 years ago

You can hide any element from your page. Example for midisounds logo

document.getElementsByClassName('MIDISounds')[0].style.visibility='hidden';

evan-007 commented 6 years ago

sure, but what do you think of an update to your component's api to handle that? like

<MIDISounds
  ref={(ref) => (this.midiSounds = ref)} 
  appElementName="root" 
  instruments={[111]} 
  drums={[2,33]} 
  hideLogo={true}
/>

I have some time to put together a pr if you'd like

surikov commented 6 years ago

Logo click shows dialog for sound properties. Hide it by CSS style if you don't need equalizer, reverberation and volume control.