Spaces:
Running
Running
Commit
·
e22c5e9
1
Parent(s):
c7d277b
cache search clicked
Browse files
viewer/src/routes/SearchButtonComponent.svelte
CHANGED
@@ -5,11 +5,19 @@
|
|
5 |
export let col;
|
6 |
|
7 |
let key = col.key;
|
|
|
8 |
|
9 |
function onEditButtonClick(row: Row) {
|
10 |
const searchName = row.Name + " hugging face";
|
11 |
window.open("https://www.google.com/search?q=" + searchName);
|
|
|
12 |
}
|
13 |
</script>
|
14 |
|
15 |
-
<button on:click={() => onEditButtonClick(row)}>{key}</button>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5 |
export let col;
|
6 |
|
7 |
let key = col.key;
|
8 |
+
let clicked = false;
|
9 |
|
10 |
function onEditButtonClick(row: Row) {
|
11 |
const searchName = row.Name + " hugging face";
|
12 |
window.open("https://www.google.com/search?q=" + searchName);
|
13 |
+
clicked = true;
|
14 |
}
|
15 |
</script>
|
16 |
|
17 |
+
<button class:clicked on:click={() => onEditButtonClick(row)}>{key}</button>
|
18 |
+
|
19 |
+
<style>
|
20 |
+
.clicked {
|
21 |
+
background-color: #ddd;
|
22 |
+
}
|
23 |
+
</style>
|