jedmund-svelte/src/lib/actions
Justin Edmund 23a844dd12 fix(actions): prevent clickOutside race condition in update method
Fix a race condition where the clickOutside action's update() method
would remove and re-add the event listener every time it was called,
even when the enabled state hadn't changed. This caused clicks to be
missed during the setTimeout delay.

Changes:
- Track previous enabled state before updating
- Only use setTimeout when transitioning from disabled to enabled
- Immediately re-add listener when enabled state stays true
- No listener changes when enabled state stays false

This ensures click-outside events are consistently detected without
gaps in event listener registration.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-07 22:13:30 -07:00
..
clickOutside.ts fix(actions): prevent clickOutside race condition in update method 2025-10-07 22:13:30 -07:00
tooltip.ts fix: drag handle actions now affect the correct block 2025-06-26 10:33:27 -04:00