diff --git a/packages/frontend/assets/sounds/syuilo/pa.mp3 b/packages/frontend/assets/sounds/syuilo/pa.mp3 new file mode 100644 index 0000000000..f3af65973d Binary files /dev/null and b/packages/frontend/assets/sounds/syuilo/pa.mp3 differ diff --git a/packages/frontend/assets/sounds/syuilo/sho.mp3 b/packages/frontend/assets/sounds/syuilo/sho.mp3 new file mode 100644 index 0000000000..c15b79ca20 Binary files /dev/null and b/packages/frontend/assets/sounds/syuilo/sho.mp3 differ diff --git a/packages/frontend/src/components/MkPullToRefresh.vue b/packages/frontend/src/components/MkPullToRefresh.vue index b0638db785..92c2e34c31 100644 --- a/packages/frontend/src/components/MkPullToRefresh.vue +++ b/packages/frontend/src/components/MkPullToRefresh.vue @@ -27,6 +27,7 @@ import { onMounted, onUnmounted, ref, useTemplateRef } from 'vue'; import { getScrollContainer } from '@@/js/scroll.js'; import { i18n } from '@/i18n.js'; import { isHorizontalSwipeSwiping } from '@/utility/touch.js'; +import * as sound from '@/utility/sound.js'; const SCROLL_STOP = 10; const MAX_PULL_DISTANCE = Infinity; @@ -200,7 +201,13 @@ function moving(event: MouseEvent | TouchEvent) { const moveHeight = moveScreenY - startScreenY!; pullDistance.value = Math.min(Math.max(moveHeight, 0), MAX_PULL_DISTANCE); + let before = isPulledEnough.value; isPulledEnough.value = pullDistance.value >= FIRE_THRESHOLD; + if (before === false && isPulledEnough.value === true) { + sound.playUrl('/client-assets/sounds/syuilo/sho.mp3', { + volume: 1, + }); + } } /** @@ -209,6 +216,9 @@ function moving(event: MouseEvent | TouchEvent) { * タイムアウトがないのでこれを最終的に実行しないと出たままになる */ function refreshFinished() { + sound.playUrl('/client-assets/sounds/syuilo/pa.mp3', { + volume: 1, + }); closeContent().then(() => { isPulling.value = false; isRefreshing.value = false;