Skip to content

fix(WL-566): vocal guidance controller - #29

Merged
nayaradias merged 7 commits into
mainfrom
fix/WL-566
Oct 5, 2026
Merged

nayaradias merged 7 commits into
mainfrom
fix/WL-566

Conversation

@DanielAraldi

Copy link
Copy Markdown
Contributor

📝 Summary

The vocal() method is now a deterministic on/off toggle on both iOS and Android:

  • If isEnabled is false, calling vocal() enables the vocal guidance and sets isEnabled to true.
  • If isEnabled is true, calling vocal() disables the vocal guidance and sets isEnabled to false.

The onVocal event always reflects the real state applied to the Aziface SDK.


✅ Checklist

Mark the items that have been completed in this PR:

⚠️ Impact

  • Low (isolated change)
  • Medium (affects multiple areas)
  • High (critical flow/risk of regression)

📱 React Native

--

🤖 Android

  • Disabling didn't reach the SDK: Disabling only changed the internal vocalGuidanceMode enum to OFF. It never updated Config.currentCustomization or called setCustomization, so the FaceTec SDK kept vocal guidance on while isEnabled was false.
  • The mode cycled through three states: Enabling went through an OFF → MINIMAL → FULL cycle: setUpVocalGuidancePlayers forced MINIMAL, and setVocalGuidanceMode then advanced it to FULL. If the on/off sound was still playing, the mode was set to OFF while isEnabled stayed true.
  • State got out of sync during a session: Calling vocal() while a session was running (IsRunning) set the mode to OFF but left isEnabled unchanged.
  • New sound players on every call: A new pair of on/off players was created each time vocal guidance was enabled.

🍎 iOS

  • Disabling didn't reach the SDK: Disabling only changed the internal vocalGuidanceMode enum to OFF. It never updated Config.currentCustomization or called setCustomization, so the FaceTec SDK kept vocal guidance on while isEnabled was false.
  • The mode cycled through three states: Enabling went through an OFF → MINIMAL → FULL cycle: setUpVocalGuidancePlayers forced MINIMAL, and setVocalGuidanceMode then advanced it to FULL. If the on/off sound was still playing, the mode was set to OFF while isEnabled stayed true.
  • State got out of sync during a session: Calling vocal() while a session was running (IsRunning) set the mode to OFF but left isEnabled unchanged.
  • New sound players on every call: A new pair of on/off players was created each time vocal guidance was enabled.
  • vocal() ran on the TurboModule background queue but accessed UIKit and the Aziface SDK.
  • getCurrentViewController() was force-unwrapped, which could crash when no view controller was found.
  • The Vocal(controller:) instance was created but never used. Debug print statements were left in the code.
  • Theme.setAppTheme (called on every initialize, setTheme and resetTheme) rebuilt the customization without the vocal guidance settings. Vocal guidance was silently lost while isEnabled stayed true.

🧪 Testing Notes

Briefly describe how this PR was tested.
Include steps to reproduce or test manually if necessary.

  • Tested on Android (device/emulator)
  • Tested on iOS (simulator/device)
  • Automated tests added/updated
  • QA passed

🔗 Related Issues / Tickets

Link any related Jira tickets, GitHub issues, or Trello cards:

--


📸 Evidence (Optional)

Attach any visual evidence of the changes (e.g., screenshots, GIFs, videos, or external links):

--

⚠️ Notes for Reviewers (Optional)

Add any relevant information that may help reviewers understand the changes faster (e.g., known issues, areas of concern, dependencies, or implementation decisions).

--

@DanielAraldi DanielAraldi self-assigned this Oct 1, 2026
@DanielAraldi DanielAraldi added the bug Something isn't working label Oct 1, 2026
@DanielAraldi DanielAraldi added the vocal guidance Vocal guidance changes label Oct 1, 2026
@DanielAraldi
DanielAraldi enabled auto-merge (squash) October 5, 2026 12:58
@nayaradias
nayaradias disabled auto-merge October 5, 2026 14:33
@nayaradias
nayaradias merged commit 19a92d6 into main Oct 5, 2026
1 check passed
@nayaradias
nayaradias deleted the fix/WL-566 branch October 5, 2026 14:33
@nayaradias

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 3.8.6 🎉

The release is available on:

Your semantic-release bot 📦🚀

@nayaradias nayaradias added the released Version released label Oct 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working released Version released vocal guidance Vocal guidance changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants