Skip to:
Content

Opened 9 years ago

Closed 8 years ago

#1940 closed defect (bug) (fixed)

Easing plugin in global.js breaks 'swing' easing

Reported by: rvenable Owned by:
Milestone: 1.5 Priority: minor
Severity: Version:
Component: Keywords:
Cc: rvenable

Description

There is a comment "ScrollTo plugin - just inline and minified" at line 1241, followed by the ScrollTo plugin on the next line, followed by another line of minified JS that is not part of the ScrollTo plugin (see: http://trac.buddypress.org/browser/trunk/bp-themes/bp-default/_inc/global.js#L1243).

I downloaded the latest version of the ScrollTo plugin and it was identical to the first line, but that second line was no where to be found.

If that line is important, can a comment be added to say what it does? If that line is obsolete could it be removed?

I ask because my site uses the jQuery qTip plugin to display tooltips, and when qTip calls jQuery.animate() it breaks. If I comment out that one mysterious JS line, my qTips work just fine, so I suspect that line is breaking jQuery.animate() somehow. Also, when I comment out that line, I can't find anything broken in the BP default theme, so I wonder if it is obsolete.

Change History (5)

#1 @r-a-y
9 years ago

The "mysterious" line looks like the jQuery easing plugin.

#2 @johnjamesjacoby
9 years ago

  • Milestone changed from 1.2 to 1.2.1

Easing is used in a few places (to roll out @mentions or the whats-new form.)

Sometimes WordPress has issues when '$' is used instead of 'jQuery'. Possible that's what you're experiencing?

#3 @rvenable
9 years ago

  • Cc rvenable added

Thanks for letting me know that code is the easing plugin, that helped me figure out why it is breaking qTip.

The problem is that qTip tries to use the 'swing' easing, which comes default in jQuery, but the version of easing that is in global.js (which looks to be 1.1.1) breaks the 'swing' easing (it does this by recreating a new easing class which overrides the old one and doesn't include 'swing' at all). So, this issue will not only affect qTip, but any javascript that tries to use the jQuery 'swing' easing.

The newest version of the easing plugin (version 1.3) doesn't break the 'swing' easing. Is there a reason version 1.1.1 was used instead of 1.3?

If you upgrade to 1.3, you should note that the names of the easings changed in 1.2, so you will have to take that into account.

#4 @rvenable
9 years ago

  • Summary changed from Mysterious minified javascript in global.js to Easing plugin in global.js breaks 'swing' easing

#5 @djpaul
8 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [3498]) Update jQuery easing plugin. Fixes #1940, #2648

Note: See TracTickets for help on using tickets.