aw-front-helpers 2.5.15 → 2.5.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,7 @@
1
- module.exports = {
2
- bootstraperMaps: require('./maps').default,
3
- bootstraperYoutube: require('./youtube').default,
4
- };
1
+ import BootstraperMaps from './maps'
2
+ import BootstraperYoutube from './youtube'
3
+
4
+ export {
5
+ BootstraperMaps,
6
+ BootstraperYoutube
7
+ }
package/classes/index.js CHANGED
@@ -1,4 +1,11 @@
1
- module.exports.GParallax = require('./globalParallax').default;
2
- module.exports.Nearby = require('./nearby').default;
3
- module.exports.FormControl = require('./formControl').default;
4
- module.exports.Sticky = require('./sticky').default;
1
+ import GParallax from './classes/globalParallax'
2
+ import Nearby from './classes/nearby'
3
+ import FormControl from './classes/formControl'
4
+ import Sticky from './classes/sticky'
5
+
6
+ export {
7
+ GParallax,
8
+ Nearby,
9
+ FormControl,
10
+ Sticky,
11
+ }
package/index.js CHANGED
@@ -1,7 +1,17 @@
1
- export const GParallax = require('./classes/globalParallax').default;
2
- export const Nearby = require('./classes/nearby').default;
3
- export const FormControl = require('./classes/formControl').default;
4
- export const Sticky = require('./classes/sticky').default;
5
- export const BootstraperMaps = require('./bootstraper/maps').default;
6
- export const BootstraperYoutube = require('./bootstraper/youtube').default;
7
- export const utils = require('./utils');
1
+ import GParallax from './classes/globalParallax'
2
+ import Nearby from './classes/nearby'
3
+ import FormControl from './classes/formControl'
4
+ import Sticky from './classes/sticky'
5
+ import BootstraperMaps from './bootstraper/maps'
6
+ import BootstraperYoutube from './bootstraper/youtube'
7
+ import * as utils from './utils'
8
+
9
+ export {
10
+ GParallax,
11
+ Nearby,
12
+ FormControl,
13
+ Sticky,
14
+ BootstraperMaps,
15
+ BootstraperYoutube,
16
+ utils
17
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aw-front-helpers",
3
- "version": "2.5.15",
3
+ "version": "2.5.17",
4
4
  "description": "Assets helpers for projects",
5
5
  "author": "Yoann Le Poupon",
6
6
  "license": "ISC",
@@ -12,6 +12,7 @@
12
12
  "dependencies": {
13
13
  "es6-symbol": "^3.1.3",
14
14
  "exif-js": "^2.3.0",
15
+ "debounce": "^2.1.0",
15
16
  "gsap": "^3.12.3"
16
17
  }
17
18
  }
@@ -1,6 +1,10 @@
1
- module.exports.min = require('./min').default;
2
- module.exports.max = require('./max').default;
3
- module.exports.slice = require('./slice').default;
4
- module.exports.combine = require('./combine').default;
5
- module.exports.without = require('./without').default;
6
- module.exports.mergeDeep = require('./merge-deep').default;
1
+ import min from './min'
2
+ import max from './max'
3
+ import slice from './slice'
4
+ import combine from './combine'
5
+ import without from './without'
6
+ import mergeDeep from './mergeDeep'
7
+
8
+ export {
9
+ min, max, slice, combine, without, mergeDeep
10
+ }
@@ -1,6 +1,4 @@
1
- module.exports.each = require('./each').default;
2
- module.exports.scroll = require('./scroll').default;
3
- module.exports.getClosest = require('./getClosest').default;
4
- module.exports.resize = require('./resize').default;
5
- module.exports.retina = require('./retina').default;
6
- module.exports.next = require('./next').default;
1
+ import retina from './retina'
2
+ export {
3
+ retina
4
+ }
@@ -1,3 +1,7 @@
1
- module.exports.once = require('./once').default;
2
- module.exports.interval = require('./interval').default;
3
- module.exports.istouch = require('./isTouch').default;
1
+ import once from './once'
2
+ import interval from './interval'
3
+ import istouch from './istouch'
4
+
5
+ export {
6
+ once, interval, istouch
7
+ }
@@ -1,4 +1,8 @@
1
- module.exports.detectVerticalSquash = require('./detectVerticalSquash').default;
2
- module.exports.resize = require('./resize').default;
3
- module.exports.thumbnail = require('./thumbnail').default;
4
- module.exports.drawImage = require('./drawImage').default;
1
+ import detectVerticalSquash from './detectVerticalSquash'
2
+ import resize from './resize'
3
+ import thumbnail from './thumbnail'
4
+ import drawImage from './drawImage'
5
+
6
+ export {
7
+ detectVerticalSquash, resize, thumbnail, drawImage
8
+ }
package/utils/index.js CHANGED
@@ -1,7 +1,10 @@
1
- module.exports.array = require('./array');
2
- module.exports.dom = require('./dom');
3
- module.exports.func = require('./func');
4
- module.exports.math = require('./math');
5
- module.exports.media = require('./media');
6
- module.exports.regex = require('./regex');
7
- module.exports.image = require('./image');
1
+ import * as array from './array'
2
+ import * as dom from './dom'
3
+ import * as func from './func'
4
+ import * as math from './math'
5
+ import * as regex from './regex'
6
+ import * as image from './image'
7
+
8
+ export {
9
+ array, dom, func, math, regex, image
10
+ }
@@ -1,2 +1,6 @@
1
- module.exports.clamp = require('./clamp').default;
2
- module.exports.hypo = require('./hypo').default;
1
+ import clamp from './clamp'
2
+ import hypo from './hypo'
3
+
4
+ export {
5
+ clamp, hypo
6
+ }
@@ -1 +1,4 @@
1
- module.exports.autoplay = require('./autoplay').default;
1
+ import autoplay from './autoplay'
2
+ export {
3
+ autoplay
4
+ }
@@ -1 +1,4 @@
1
- module.exports.email = require('./email').default;
1
+ import email from './email'
2
+ export {
3
+ email
4
+ }
package/utils/dom/each.js DELETED
@@ -1,6 +0,0 @@
1
- export default (nodelist, callback) => {
2
- let i = -1;
3
- const l = nodelist.length;
4
-
5
- while (++i < l) callback({ el: nodelist.item(i), index: i });
6
- };
@@ -1,11 +0,0 @@
1
- /**
2
- * Get the closest matching element up the DOM tree.
3
- * @deprecated since version 2.5.0
4
- * @private
5
- * @param {Element} elem Starting element
6
- * @param {String} selector Selector to match against
7
- * @return {Boolean|Element} Returns null if not match found
8
- */
9
- export default function (elem, selector) {
10
- return elem.closest(selector);
11
- }
package/utils/dom/next.js DELETED
@@ -1,9 +0,0 @@
1
- var getNext = function (el) {
2
- let next = el.nextSibling;
3
- if (next && next.nodeType === 3) {
4
- return getNext(next);
5
- }
6
- return next;
7
- };
8
-
9
- export default getNext;
@@ -1,3 +0,0 @@
1
- export default () => {
2
- return 'onorientationchange' in window ? 'orientationchange' : 'resize';
3
- };
@@ -1,13 +0,0 @@
1
- export default (opts) => {
2
- if (opts === 'y') {
3
- if (window.scrollY) return window.scrollY;
4
- return document.documentElement.clientHeight
5
- ? document.documentElement.scrollTop
6
- : document.body.scrollTop;
7
- } else {
8
- if (window.pageXOffset) return window.pageXOffset;
9
- return document.documentElement.clientWidth
10
- ? document.documentElement.scrollLeft
11
- : document.body.scrollLeft;
12
- }
13
- };
File without changes