version/0.6 #4
|
@ -94,7 +94,7 @@ const Search: React.FC<SearchProps> = ({ setBooks }) => {
|
||||||
}
|
}
|
||||||
|
|
||||||
const copyToClipboard = () => {
|
const copyToClipboard = () => {
|
||||||
const searchBase = `${window.location.host}/?`;
|
const searchBase = `${window.location.protocol}//${window.location.host}/?`;
|
||||||
const searchQuery = encodeURIComponent(`title=${title}&author=${author}&language=${language}&publisher=${publisher}&isbn=${isbn}&extension=${extension}`)
|
const searchQuery = encodeURIComponent(`title=${title}&author=${author}&language=${language}&publisher=${publisher}&isbn=${isbn}&extension=${extension}`)
|
||||||
|
|
||||||
navigator.clipboard.writeText(`${searchBase}${searchQuery}`).then(() => {
|
navigator.clipboard.writeText(`${searchBase}${searchQuery}`).then(() => {
|
||||||
|
|
Loading…
Reference in New Issue