diff --git a/README.md b/README.md index 75cc790..5e3b114 100644 --- a/README.md +++ b/README.md @@ -141,7 +141,7 @@ var options = { lockY: Boolean, // only move on the Y axis catchDistance: Number, // distance to recycle previous joystick in // 'semi' mode - dynamic_page: Boolean, // Enable if the page has dynamically visible elements + dynamicPage: Boolean, // Enable if the page has dynamically visible elements }; ``` @@ -253,7 +253,7 @@ Locks joystick's movement to the x (horizontal) axis ### `options.lockY` defaults to false Locks joystick's movement to the y (vertical) axis -### `options.dynamic_page` defaults to true +### `options.dynamicPage` defaults to true Enable if the page has dynamically visible elements such as for Vue, React, Angular or simply some CSS hiding or showing some DOM. ---- diff --git a/src/collection.js b/src/collection.js index 84816e6..95817c8 100644 --- a/src/collection.js +++ b/src/collection.js @@ -34,7 +34,7 @@ function Collection (manager, options) { restOpacity: 0.5, lockX: false, lockY: false, - dynamic_page: false + dynamicPage: false }; self.config(options); @@ -378,7 +378,7 @@ Collection.prototype.processOnMove = function (evt) { return; } - if (opts.dynamic_page) { + if (opts.dynamicPage) { var scroll = u.getScroll(); pos = nipple.el.getBoundingClientRect(); nipple.position = {