mirror of
https://github.com/Noratrieb/slides.git
synced 2026-01-14 16:35:07 +01:00
switch old toArray helper to Array.from
This commit is contained in:
parent
6ff4e9306c
commit
2540712714
10 changed files with 111 additions and 113 deletions
|
|
@ -1,4 +1,4 @@
|
|||
import { extend, toArray, createStyleSheet } from '../utils/util.js'
|
||||
import { queryAll, extend, createStyleSheet } from '../utils/util.js'
|
||||
|
||||
/**
|
||||
* Automatically animates matching elements across
|
||||
|
|
@ -87,12 +87,12 @@ export default class AutoAnimate {
|
|||
reset() {
|
||||
|
||||
// Reset slides
|
||||
toArray( this.Reveal.getRevealElement().querySelectorAll( '[data-auto-animate]:not([data-auto-animate=""])' ) ).forEach( element => {
|
||||
queryAll( this.Reveal.getRevealElement(), '[data-auto-animate]:not([data-auto-animate=""])' ).forEach( element => {
|
||||
element.dataset.autoAnimate = '';
|
||||
} );
|
||||
|
||||
// Reset elements
|
||||
toArray( this.Reveal.getRevealElement().querySelectorAll( '[data-auto-animate-target]' ) ).forEach( element => {
|
||||
queryAll( this.Reveal.getRevealElement(), '[data-auto-animate-target]' ).forEach( element => {
|
||||
delete element.dataset.autoAnimateTarget;
|
||||
} );
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue