Releases: NoriginMedia/Norigin-Spatial-Navigation
Releases · NoriginMedia/Norigin-Spatial-Navigation
New "useGetBoundingClientRect" config option
New init
config option useGetBoundingClientRect
that affects the measurements of sizes and coordinates.
Added setThrottle
Added
- Add setThrottle to dynamically change throttle time. In relation to issue #45
Changed
- Remove event listeners for unbindEventHandlers regardless of throttle value
Fix focus lost
Changed
- Update
parentFocusKey
whenremoveFocusable
- Fix issue with
destroy
(addedbind
)
es5 compliant (removed Reflect)
Replaced Reflect.deleteProperty
with delete
, to be es5 compliant.
Accept `focusDetails` argument in focusSelf
Added focusDetails
argument in focusSelf
(and also in setFocus
).
Also, I modified the focusDetails interface to include either an event, nativeEvent or any key-value combination required. This object will be received at the onFocus callback.
Output bundle is targeting ES5
Previous versions still had some arrow functions in the bundle coming from the Webpack itself, even though TS config had ES5
as target. Now the bundle is ES5 compatible.
React v18 StrictMode support
[1.1.0]
Added
- Support for React v18 StrictMode. Added
useEffectOnce
to avoid multiple effect runs on mount that was breaking the
generation of thefocusKey
s.
Fixed
- Few TS errors that somehow not being checked when the app is built and published ¯_(ツ)_/¯.
getCurrentFocusKey + multiple codes per key direction
Added generic P type to be passed to useFocusable, fixed lodash imports
Added
- Added generic P type for the props passed to
useFocusable
hook that is available in all callbacks that bounce props back.
Changed
- Changed all
lodash
imports to cherry-picked ones to avoid the wholelodash
lib to be bundled in the project.
Fixed Webpack issue in node env, added eslint plugins
[1.0.4]
Added
- Eslint dependencies required by
eslint-config-airbnb
Fixed
- Fixed issue in Node environment - Webpack global object is now
this
instead ofself