Skip to content
This repository has been archived by the owner on May 20, 2022. It is now read-only.

Commit

Permalink
fix megamenu js
Browse files Browse the repository at this point in the history
  • Loading branch information
Danilo Spinelli committed May 23, 2017
1 parent 3c667b9 commit cdaf014
Showing 1 changed file with 3 additions and 13 deletions.
16 changes: 3 additions & 13 deletions src/components/megamenu/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,22 +118,12 @@ $(document).ready(function() {
})

$('.' + opts.topNavItemClass + ' > a').each((i, el) => {
const $target = $(el).parent().find('.' + opts.panelClass)
const $target = $(el).parent()
.find('.' + opts.panelClass)
.not(el)

if (el && $target.length > 0) {
new Popper(el, $target, {
// onUpdate: (data) => {
// const $el = $(data.instance.popper)
// if ($el.offset().left + $el.outerWidth() > $(window).width()) {
// $el.css({ width: '95%' })
// }
// },
// onCreate: (data) => {
// const $el = $(data.instance.popper)
// if ($el.offset().left + $el.outerWidth() > $(window).width()) {
// $el.css({ width: '95%' })
// }
// },
placement: 'bottom',
modifiers: {
arrow: {
Expand Down

0 comments on commit cdaf014

Please sign in to comment.