longandCursor edc9993403 fix(metronome): 修复 iOS 真机静音键模式下无声音
iOS 微信小程序的 InnerAudioContext 默认会受系统侧边静音键影响,
单实例 obeyMuteSwitch = false 在 iOS 上不可靠,必须调用全局
API setInnerAudioOption 才能正常发声。

- App.vue onLaunch 调用 uni.setInnerAudioOption({
    obeyMuteSwitch: false, mixWithOther: true })
- useMetronome.preload() 进页面时再调一次保险
- AudioPool.play() 改用 stop() + play() 替代 seek(0) + play(),
  iOS 上 seek(0) 不一定能复位播放进度
- 预热改用 volume 0.01 极小音量替代 volume 0,iOS 上音量为 0
  可能不会真正完成音频解码

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-25 11:48:16 +08:00
2026-05-07 10:48:21 +08:00
2026-03-27 18:06:12 +08:00
2026-04-13 09:44:10 +08:00
2026-05-22 17:55:54 +08:00
2026-03-01 14:17:59 +08:00
2026-03-01 14:17:59 +08:00
2026-03-20 13:56:40 +08:00
2026-05-22 18:00:22 +08:00
2026-03-23 18:02:16 +08:00
1
2026-04-29 18:41:39 +08:00
2026-03-09 09:55:04 +08:00
2026-05-25 11:33:01 +08:00
2026-04-20 16:01:59 +08:00
2026-04-20 16:01:59 +08:00
2026-05-08 16:07:39 +08:00
1
2026-04-21 15:56:04 +08:00
2026-03-01 14:17:59 +08:00
S
Description
No description provided
MIT
475 MiB
Languages
JavaScript 28.7%
Vue 25.2%
java 24.1%
PHP 14.6%
TypeScript 4.2%
Other 3.2%