mirror of
https://github.com/iptv-org/iptv-org.github.io.git
synced 2025-05-13 02:20:06 -04:00
Update the results after pressing the Back button
This commit is contained in:
parent
59dde05ee9
commit
f22f3cb680
3 changed files with 40 additions and 15 deletions
|
@ -1,6 +1,6 @@
|
|||
<script>
|
||||
import dayjs from 'dayjs'
|
||||
import { search, query, hasQuery, channels } from '../store.js'
|
||||
import { search, query, hasQuery, channels, setSearchParam } from '../store.js'
|
||||
|
||||
export let data
|
||||
export let close
|
||||
|
@ -40,9 +40,12 @@
|
|||
function searchBy(name, value) {
|
||||
value = value.includes(' ') ? `"${value}"` : value
|
||||
const q = `${name}:${value}`
|
||||
query.set(q)
|
||||
hasQuery.set(true)
|
||||
search(q)
|
||||
if($query !== q) {
|
||||
query.set(q)
|
||||
hasQuery.set(true)
|
||||
search(q)
|
||||
setSearchParam('q', q)
|
||||
}
|
||||
close()
|
||||
}
|
||||
</script>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue