@pushword/js-helper 0.0.81 → 0.0.82

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/helpers.js +2 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pushword/js-helper",
3
- "version": "0.0.81",
3
+ "version": "0.0.82",
4
4
  "description": "Pushword front end helpers. ",
5
5
  "author": "Robin@PiedWeb <contact@piedweb.com>",
6
6
  "license": "MIT",
package/src/helpers.js CHANGED
@@ -202,9 +202,9 @@ export function addClassForNormalUser(attribute = 'data-acinb') {
202
202
  }
203
203
  if (startScrolling === 4) {
204
204
  [].forEach.call(document.querySelectorAll('[' + attribute + ']'), function (element) {
205
- var classToAdd = element.getAttribute(attribute);
205
+ var classToAdd = element.getAttribute(attribute).split(' ');
206
206
  element.removeAttribute(attribute);
207
- element.classList.add(classToAdd);
207
+ element.classList.add(...classToAdd);
208
208
  if ((' ' + classToAdd + ' ').contains(' block ')) {
209
209
  element.classList.remove('hidden');
210
210
  }