User talk:Plumtree/Sound

From Xenharmonic Wiki
Jump to navigation Jump to search

First impression

It's really great to see that in action, that's what I had in mind when I requested to enable user scripts and CSS for the wiki, but I had never the time (nor the expertise) to get so far…

I briefly looked over the JavaScript, painfully remembering (given your for loops) that let is not available due to an embarrassing bug in MediaWiki (const works, by the way).

What I found that may be added is a way to stop (maybe pause) playing sound. If we are ever dealing with longer sound samples and someone clicks on them rather accidentally, I would estimate the need to quickly stop all output as high.

I'm not sure is this quick review will help you. If you have things in mind I should test, please let me know.

BTW: I'm using the Timeless skin, which is really great in most aspects. The only downside (and this is a heavy one!) is that I't all to easy to miss the notification when someone changes your user discussion. That's why I read your message only today, despite visiting the wiki nearly every day. If you perhaps know how to make it stand out like in Vector skin, please let me know.

Best regards --Xenwolf (talk) 19:07, 26 October 2022 (UTC)

PS: in case you want top experiment with other skins, you'll find it here: https://en.xen.wiki/w/Special:Preferences#mw-prefsection-rendering --Xenwolf (talk) 19:09, 26 October 2022 (UTC)
Thanks for the feedback; I'll add stop functionality, and perhaps pause as well if I figure out how exactly. I don't have any ideas on what else to test right now (at least those that'd differ much from existing examples) - the JS part of the project is supposed to be a minimal interface to Web Audio API usable for different purposes by templates and modules.

I'll give Timeless a try later. Personally, I prefer having a tab with recent changes always open to relying on notifications. --Plumtree (talk) 20:52, 26 October 2022 (UTC)
Stopping and pausing have been implemented. Now any element with data-lock attribute stops playing the sequence on a repeated click. If data-pause is also set, current time shift is saved and used on subsequent clicks. Class sequence-audio-paused is also handled in CSS; perhaps I'll find better colours later. --Plumtree (talk) 12:30, 28 October 2022 (UTC)