Skip to content

Commit

Permalink
Add handler for search event, opens new tab for searching on player
Browse files Browse the repository at this point in the history
  • Loading branch information
auggod committed Oct 7, 2021
1 parent fa04ca1 commit 898a9e4
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/assets/js/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,10 @@ function search (selector) {
state.params = {} // nanochoo does not have a router

state.cache(Search, 'search')

emitter.on('search', (q) => {
window.open(`https://beta.stream.resonate.coop/search?q=${q}`, '_blank')
})
})

app.view((state, emit) => {
Expand Down

0 comments on commit 898a9e4

Please sign in to comment.