Releases: breakthestatic/hass-sidebar-swipe
v2.1.0 Beta 1
Adds an invert
option which switches the swipe direction (primarily for RTL languages, fixes #4). In addition to this, the swipe logic was cleaned up a bit regarding the significant direction logic (i.e. better delta x > delta y detection).
Full Changelog: v2.0.2...v2.1.0-beta.1
v2.0.2
v2.0.1
Fixes issue where swiping beyond the end_threshold
but backtracking and ending the touch before the threshold trigger the drawer open. Updated logic should ensure that only swipes that finish beyond the end_threshold
trigger the drawer.
v2.0.0
Breaking Changes:
- The
check_visibilty
option, which was deprecated in v1.0.4, has been removed. - Previously, only
touchstart
events were being suppressed from propagation when using theprevent_others
option. This release suppressestouchmove
andtouchend
events as well when the option is enabled. - Multi-touch gestures (e.g. two/three finger swipes) are now ignored when opening the drawer.
New Features:
- Exclusion list - If your dashboard has any actionable items that render within the starting threshold, you can now add them to this list, which will be checked upon the start of each gesture. If a gesture begins within the starting threshold but also happens to be over an item in the list, the gesture will be suppressed. The
exclusions
option accepts a list of CSS Selectors for targeting.
Full Changelog: v1.0.4...v2.0.0
v2.0.0-beta.1
First major version bump, primarily due to two breaking changes:
- The
check_visibilty
option, which was deprecated in v1.0.4, has been removed. There didn't seem to be any good reasons to allow triggering the sidebar when it was actively being suppressed. - Previously, only
touchstart
events were being suppressed from propagation when using theprevent_others
option. This release suppressestouchmove
andtouchend
events as well when the option is enabled.
In addition to the breaking changes noted above, this release also adds a new feature - an exclusion list. If your dashboard has any actionable items that render within the starting threshold, you can now add them to an exclusion list, which will be checked upon the start of each gesture. If a gesture begins within the starting threshold but also happens to be over an item in the exclusion list, the gesture will be suppressed. The exclusions
option accepts a list of CSS Selectors for targeting.
Full Changelog: v1.0.3...v2.0.0-beta.1
v1.0.4
Adds new check to prevent unintended activation when the vertical distance traveled is greater than the horizontal (indicating it's not actually a sidebar swipe).
v1.0.3
Fixes interaction issue with non-moving touch events (taps) and lock_vertical_scroll
. Previously, with lock_vertical_scroll
enabled (the default), if a touch event started within the trigger zone, but did not actually move at least 1px, the touchend
logic would never be reached and the body would remain locked. This is most prevalent when tapping buttons within the trigger zone (e.g. tapping the back arrow in the header inside a lovelace subview).
The code has been updated to completely ignore touchmove
events, as they aren't actually needed to determine total distance traveled; touchend
contains a clientX
property that provides the same data that I was previously pulling from the last touchmove
event.
This also contains a small fix to correctly restore current scroll position when the drawer is opened via the hamburger menu instead of the swipe gesture.
v1.0.2
Fix issue with source map reference being included in production builds. No functionality changes, but prevents a missing source map warning from appearing in the browser console logs.
v1.0.1
Added a check to ensure ha-sidebar
exists (and isn't hidden) before initializing the swipe logic. This should prevent issues with mods like kiosk mode that hide/remove the sidebar.
v1.0.0 First release
Promoting to first official release after testing by several members of the home assistant community.