How to use the @pluginjs/utils.parseDataOptions function in @pluginjs/utils

To help you get started, we’ve selected a few @pluginjs/utils examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github pluginjs / pluginjs / modules / parallax / src / main.js View on Github external
addClass(
          this.classes.CONTAINER,
          closest(this.options.container, this.element)
        )
      } else {
        wrap(`<div class="${this.classes.CONTAINER}"></div>`, this.element)
      }

      this.container = parentWith(
        hasClass(this.classes.CONTAINER),
        this.element
      )
    }

    this.containerOptions = this.container.dataset
      ? parseDataOptions(this.container.dataset)
      : {}

    if (this.containerOptions.height) {
      this.container.style.height = this.setContainerHeight()
    }
  }
github pluginjs / pluginjs / modules / toast / samples / src / sections / loader / index.js View on Github external
return e.addEventListener('click', e => {
    Toast.open(parseDataOptions(e.target.dataset))
  })
})
github pluginjs / pluginjs / modules / toast / samples / src / sections / type / index.js View on Github external
return e.addEventListener('click', e => {
    Toast.open(parseDataOptions(e.target.dataset))
  })
})
github pluginjs / pluginjs / modules / toast / samples / src / sections / closeable / index.js View on Github external
return e.addEventListener('click', e => {
    Toast.open(parseDataOptions(e.target.dataset))
  })
})
github pluginjs / pluginjs / modules / decorator / src / optionable.js View on Github external
plugin.prototype.getDataOptions = function() {
        if (!this.element) {
          return {}
        }

        return parseDataOptions(this.element.dataset)
      }
    } else {
github pluginjs / pluginjs / modules / toast / samples / src / sections / stack / index.js View on Github external
return e.addEventListener('click', e => {
    Toast.open(parseDataOptions(e.target.dataset))
  })
})
github pluginjs / pluginjs / modules / toast / samples / src / sections / duration / index.js View on Github external
return e.addEventListener('click', e => {
    Toast.open(parseDataOptions(e.target.dataset))
  })
})
github pluginjs / pluginjs / modules / toast / samples / src / sections / effect / index.js View on Github external
return e.addEventListener('click', e => {
    Toast.open(parseDataOptions(e.target.dataset))
  })
})