mirror of
https://iceshrimp.dev/limepotato/jormungandr-bite.git
synced 2024-11-24 10:57:30 -07:00
maybe when the ripple is called?
This commit is contained in:
parent
9a2dc894c1
commit
73dcff2793
2 changed files with 2 additions and 1 deletions
|
@ -67,6 +67,7 @@ function star(ev?: MouseEvent): void {
|
||||||
const x = rect.left + el.offsetWidth / 2;
|
const x = rect.left + el.offsetWidth / 2;
|
||||||
const y = rect.top + el.offsetHeight / 2;
|
const y = rect.top + el.offsetHeight / 2;
|
||||||
os.popup(Ripple, { x, y }, {}, "end");
|
os.popup(Ripple, { x, y }, {}, "end");
|
||||||
|
sound.play("reaction");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
|
@ -62,7 +62,6 @@ const buttonRef = ref<HTMLElement>();
|
||||||
|
|
||||||
function toggleStar(ev?: MouseEvent): void {
|
function toggleStar(ev?: MouseEvent): void {
|
||||||
pleaseLogin();
|
pleaseLogin();
|
||||||
sound.play("reaction");
|
|
||||||
if (!props.reacted) {
|
if (!props.reacted) {
|
||||||
os.api("notes/reactions/create", {
|
os.api("notes/reactions/create", {
|
||||||
noteId: props.note.id,
|
noteId: props.note.id,
|
||||||
|
@ -76,6 +75,7 @@ function toggleStar(ev?: MouseEvent): void {
|
||||||
const x = rect.left + el.offsetWidth / 2;
|
const x = rect.left + el.offsetWidth / 2;
|
||||||
const y = rect.top + el.offsetHeight / 2;
|
const y = rect.top + el.offsetHeight / 2;
|
||||||
os.popup(Ripple, { x, y }, {}, "end");
|
os.popup(Ripple, { x, y }, {}, "end");
|
||||||
|
sound.play("reaction");
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
os.api("notes/reactions/delete", {
|
os.api("notes/reactions/delete", {
|
||||||
|
|
Loading…
Reference in a new issue