Skip to content

Commit

Permalink
Update to version 1.7.3
Browse files Browse the repository at this point in the history
  • Loading branch information
micku7zu committed Oct 29, 2022
1 parent e80bf21 commit 7f606cd
Show file tree
Hide file tree
Showing 10 changed files with 36 additions and 24 deletions.
9 changes: 5 additions & 4 deletions dist/vanilla-tilt.babel.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ var classCallCheck = function (instance, Constructor) {
* Created by Sergiu Șandor (micku7zu) on 1/27/2017.
* Original idea: https://github.com/gijsroge/tilt.js
* MIT License.
* Version 1.7.2
* Version 1.7.3
*/

var VanillaTilt = function () {
Expand Down Expand Up @@ -361,7 +361,8 @@ var VanillaTilt = function () {
"width": "100%",
"height": "100%",
"overflow": "hidden",
"pointer-events": "none"
"pointer-events": "none",
"border-radius": "inherit"
});

Object.assign(this.glareElement.style, {
Expand Down Expand Up @@ -426,8 +427,8 @@ var VanillaTilt = function () {
* @param {number} settings.scale - 2 = 200%, 1.5 = 150%, etc..
* @param {number} settings.speed - Speed of the enter/exit transition
* @param {boolean} settings.transition - Set a transition on enter/exit
* @param {string|null} settings.axis - What axis should be disabled. Can be X or Y
* @param {boolean} settings.glare - What axis should be disabled. Can be X or Y
* @param {string|null} settings.axis - What axis should be enabled. Can be "x" or "y"
* @param {boolean} settings.glare - if it should have a "glare" effect
* @param {number} settings.max-glare - the maximum "glare" opacity (1 = 100%, 0.5 = 50%)
* @param {boolean} settings.glare-prerender - false = VanillaTilt creates the glare elements for you, otherwise
* @param {boolean} settings.full-page-listening - If true, parallax effect will listen to mouse move events on the whole document, not only the selected element
Expand Down
2 changes: 1 addition & 1 deletion dist/vanilla-tilt.babel.min.js

Large diffs are not rendered by default.

9 changes: 5 additions & 4 deletions dist/vanilla-tilt.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ var VanillaTilt = (function () {
* Created by Sergiu Șandor (micku7zu) on 1/27/2017.
* Original idea: https://github.com/gijsroge/tilt.js
* MIT License.
* Version 1.7.2
* Version 1.7.3
*/

class VanillaTilt {
Expand Down Expand Up @@ -350,7 +350,8 @@ class VanillaTilt {
"width": "100%",
"height": "100%",
"overflow": "hidden",
"pointer-events": "none"
"pointer-events": "none",
"border-radius": "inherit",
});

Object.assign(this.glareElement.style, {
Expand Down Expand Up @@ -418,8 +419,8 @@ class VanillaTilt {
* @param {number} settings.scale - 2 = 200%, 1.5 = 150%, etc..
* @param {number} settings.speed - Speed of the enter/exit transition
* @param {boolean} settings.transition - Set a transition on enter/exit
* @param {string|null} settings.axis - What axis should be disabled. Can be X or Y
* @param {boolean} settings.glare - What axis should be disabled. Can be X or Y
* @param {string|null} settings.axis - What axis should be enabled. Can be "x" or "y"
* @param {boolean} settings.glare - if it should have a "glare" effect
* @param {number} settings.max-glare - the maximum "glare" opacity (1 = 100%, 0.5 = 50%)
* @param {boolean} settings.glare-prerender - false = VanillaTilt creates the glare elements for you, otherwise
* @param {boolean} settings.full-page-listening - If true, parallax effect will listen to mouse move events on the whole document, not only the selected element
Expand Down
2 changes: 1 addition & 1 deletion dist/vanilla-tilt.min.js

Large diffs are not rendered by default.

12 changes: 10 additions & 2 deletions lib/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,14 @@ If you want to use this library in IE, you need to include a CustomEvent polyfil
scale: 1, // 2 = 200%, 1.5 = 150%, etc..
speed: 300, // Speed of the enter/exit transition
transition: true, // Set a transition on enter/exit.
axis: null, // What axis should be disabled. Can be X or Y.
axis: null, // What axis should be enabled. Can be "x" or "y".
reset: true, // If the tilt effect has to be reset on exit.
easing: "cubic-bezier(.03,.98,.52,.99)", // Easing on enter/exit.
glare: false, // if it should have a "glare" effect
"max-glare": 1, // the maximum "glare" opacity (1 = 100%, 0.5 = 50%)
"glare-prerender": false, // false = VanillaTilt creates the glare elements for you, otherwise
// you need to add .js-tilt-glare>.js-tilt-glare-inner by yourself
"mouse-event-element": null, // css-selector or link to HTML-element what will be listen mouse events
"mouse-event-element": null, // css-selector or link to an HTML-element that will be listening to mouse events
"full-page-listening": false, // If true, parallax effect will listen to mouse move events on the whole document, not only the selected element
gyroscope: true, // Boolean to enable/disable device orientation detection,
gyroscopeMinAngleX: -45, // This is the bottom limit of the device angle on X axis, meaning that a device rotated at this angle would tilt the element as if the mouse was on the left border of the element;
Expand Down Expand Up @@ -115,6 +115,14 @@ Original library author: [Gijs Rogé](https://twitter.com/GijsRoge)
- [Sander Moolin](https://github.com/SaFrMo)
- [rrroyal](https://github.com/rrroyal) (Whole document mouse events listening)

### Other projects

#### [Quick Cursor: One-Handed mode](https://play.google.com/store/apps/details?id=com.quickcursor) (Android app)
Play Store link: https://play.google.com/store/apps/details?id=com.quickcursor

### Buy me a beer 🍻
If you want to thank me for vanilla-tilt.js or Quick Cursor Android app, you can [donate on PayPal](https://www.paypal.me/micku7zu?locale.x=en_US): https://www.paypal.me/micku7zu?locale.x=en_US

### License

MIT License
9 changes: 5 additions & 4 deletions lib/vanilla-tilt.es2015.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Created by Sergiu Șandor (micku7zu) on 1/27/2017.
* Original idea: https://github.com/gijsroge/tilt.js
* MIT License.
* Version 1.7.2
* Version 1.7.3
*/

class VanillaTilt {
Expand Down Expand Up @@ -347,7 +347,8 @@ class VanillaTilt {
"width": "100%",
"height": "100%",
"overflow": "hidden",
"pointer-events": "none"
"pointer-events": "none",
"border-radius": "inherit",
});

Object.assign(this.glareElement.style, {
Expand Down Expand Up @@ -415,8 +416,8 @@ class VanillaTilt {
* @param {number} settings.scale - 2 = 200%, 1.5 = 150%, etc..
* @param {number} settings.speed - Speed of the enter/exit transition
* @param {boolean} settings.transition - Set a transition on enter/exit
* @param {string|null} settings.axis - What axis should be disabled. Can be X or Y
* @param {boolean} settings.glare - What axis should be disabled. Can be X or Y
* @param {string|null} settings.axis - What axis should be enabled. Can be "x" or "y"
* @param {boolean} settings.glare - if it should have a "glare" effect
* @param {number} settings.max-glare - the maximum "glare" opacity (1 = 100%, 0.5 = 50%)
* @param {boolean} settings.glare-prerender - false = VanillaTilt creates the glare elements for you, otherwise
* @param {boolean} settings.full-page-listening - If true, parallax effect will listen to mouse move events on the whole document, not only the selected element
Expand Down
9 changes: 5 additions & 4 deletions lib/vanilla-tilt.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ var classCallCheck = function (instance, Constructor) {
* Created by Sergiu Șandor (micku7zu) on 1/27/2017.
* Original idea: https://github.com/gijsroge/tilt.js
* MIT License.
* Version 1.7.2
* Version 1.7.3
*/

var VanillaTilt = function () {
Expand Down Expand Up @@ -360,7 +360,8 @@ var VanillaTilt = function () {
"width": "100%",
"height": "100%",
"overflow": "hidden",
"pointer-events": "none"
"pointer-events": "none",
"border-radius": "inherit"
});

Object.assign(this.glareElement.style, {
Expand Down Expand Up @@ -425,8 +426,8 @@ var VanillaTilt = function () {
* @param {number} settings.scale - 2 = 200%, 1.5 = 150%, etc..
* @param {number} settings.speed - Speed of the enter/exit transition
* @param {boolean} settings.transition - Set a transition on enter/exit
* @param {string|null} settings.axis - What axis should be disabled. Can be X or Y
* @param {boolean} settings.glare - What axis should be disabled. Can be X or Y
* @param {string|null} settings.axis - What axis should be enabled. Can be "x" or "y"
* @param {boolean} settings.glare - if it should have a "glare" effect
* @param {number} settings.max-glare - the maximum "glare" opacity (1 = 100%, 0.5 = 50%)
* @param {boolean} settings.glare-prerender - false = VanillaTilt creates the glare elements for you, otherwise
* @param {boolean} settings.full-page-listening - If true, parallax effect will listen to mouse move events on the whole document, not only the selected element
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vanilla-tilt",
"version": "1.7.2",
"version": "1.7.3",
"description": "A smooth 3D tilt javascript library forked from Tilt.js",
"main": "lib/vanilla-tilt.js",
"module_es2015": "lib/vanilla-tilt.es2015.js",
Expand Down
2 changes: 1 addition & 1 deletion src/vanilla-tilt.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Created by Sergiu Șandor (micku7zu) on 1/27/2017.
* Original idea: https://github.com/gijsroge/tilt.js
* MIT License.
* Version 1.7.2
* Version 1.7.3
*/

export default class VanillaTilt {
Expand Down
4 changes: 2 additions & 2 deletions vanilla-tilt.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Extended Type definitions for vanilla-tilt 1.7.0
// Extended Type definitions for vanilla-tilt 1.7.3
// Project: https://github.com/micku7zu/vanilla-tilt.js
// Definitions by: Livio Brunner <https://github.com/BrunnerLivio>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
Expand Down Expand Up @@ -43,7 +43,7 @@ export interface TiltOptions {
*/
transition?: boolean;
/**
* What axis should be disabled. Can be X or Y.
* What axis should be enabled. Can be "x" or "y".
*/
axis?: null | "x" | "y";
/**
Expand Down

0 comments on commit 7f606cd

Please sign in to comment.