Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update jquery + jquery plugins to the last versions #5663

Closed
mattab opened this issue Jun 4, 2008 · 33 comments
Closed

Update jquery + jquery plugins to the last versions #5663

mattab opened this issue Jun 4, 2008 · 33 comments
Assignees
Labels
Major Indicates the severity or impact or benefit of an issue is much higher than normal but not critical. Task Indicates an issue is neither a feature nor a bug and it's purely a "technical" change.
Milestone

Comments

@mattab
Copy link
Member

mattab commented Jun 4, 2008

Task
Update javascript librairies to their latest/fastest releases: jquery, jquery plugins, swfobject.

jquery

http://feeds.feedburner.com/~r/ajaxian/~3/303858275/jquery-release-126-performance-improvements-and-dimensions-plugin-added-to-core

We are using fast changing libraries in Piwik. We should try to upgrade the libraries as often as possible, every few months, so we stay in line with the APIs and latest features.

A new release of jQuery is out 1.2.6. The headlines on improvements:
\* Event handling: 103%
\* CSS selectors: 13%
\* .offset: 21%
\* .css: 25%

Lots of other fixes, but the most important, IMHO, is the inclusion of Brandon Aarons Dimensions plugin cross browser support for find element dimensions, offsets and positioning in the jQuery core. Check out the release notes here.

As we are using dimensions and jquery, we definitely should upgrade to this new version.

testing
- http://dev.piwik.org/trac/wiki/HowToTestUI Go through the UI checklist after the upgrade to make sure it hasn’t broken the ui on ie/ff at least

@anonymous-matomo-user
Copy link

jquery is really sure to make an automatic update without tests from piwik time ? And it’s a little useless, because the new features (without some improvements) aren’t used yet (piwik can’t be based on a future-release of jquery)

@pebosi
Copy link
Contributor

pebosi commented Nov 8, 2008

i tested (http://dev.piwik.org/trac/wiki/HowToTestUI) with firefox and used jquery-1.2.6-min, following results:

  1. Test Include/Exclude low population
    - Does not work, but maby there are to less entries, tried on action→pages and providers
  1. Actions pages table failed on “Different styles for Odd/Even lines”
  1. Actions Tables are not sortable

maybe the weren’t before…

  1. Make sure that already added widgets cannot be added again

Its not klickable but if i click there is a new box wich says “Loading widget please weight” and im still waiting :)

last thing i saw is that the menus of language- and site selection are visible and without arrows…

@pebosi
Copy link
Contributor

pebosi commented Nov 8, 2008

next test was with updated swfobject, no problems.

@pebosi
Copy link
Contributor

pebosi commented Nov 8, 2008

sorry, the new swfobject hides all graphs.

@pebosi
Copy link
Contributor

pebosi commented Nov 8, 2008

what other jquery plugins are to be tested?

@robocoder
Copy link
Contributor

jQuery (current: 1.2.2; latest: 1.2.6)

SWFObject (current: 1.5; latest 2.1)
swfobject plugin (not used; latest: 1.0.3) http://jquery.thewikies.com/swfobject/

fdd2div (current: 1.0; latest: 1.0.1) Don’t know if it fixes ticket #451.
superfish (current: 1.4.1; latest: 1.4.8)
thickbox (current/latest: 3.1)
tooltip (current: 1.1; latest: 1.3)

truncate (version ???) Could look into using http://www.reindel.com/truncate/ (v2.3)

@robocoder
Copy link
Contributor

re: pebosi’s observations re: the latest swfobject; the API changed, i.e., the object interface is gone

matt added in email: “Also we have patched some libs (UI sortable, fdd2div, superfish) so let’s not update these ones.”

@robocoder
Copy link
Contributor

Attachment: swfobject 2.1 update: replace 3 files, add libs/swfobject/expressInstall.swf (though not currently used), and remove libs/swfobject/README.txt
[243_swfobject.zip](http://issues.piwik.org/attachments/5663/243_swfobject.zip)

@robocoder
Copy link
Contributor

Attachment: Sync with sparkline cvs repository (minor bug fixes & dual license change)
[243_sparkline.zip](http://issues.piwik.org/attachments/5663/243_sparkline.zip)

@robocoder
Copy link
Contributor

fdd2div (original and modified) are broken by jquery 1.2.6

@robocoder
Copy link
Contributor

Notes: ui.mouse was moved into the jquery ui.core in 1.5.3; similarly, calendar was adopted as ui.datepicker

@robocoder
Copy link
Contributor

Attachment: Fix for jquery 1.2.6.
[fdd2div-modified.js](http://issues.piwik.org/attachments/5663/fdd2div-modified.js)

@robocoder
Copy link
Contributor

Attachment: Update to jquery-tooltip from 1.1 to 1.3; minor changes as a result of $.fn.Toolkit() being deprecated & removed in favor of $.fn.toolkit()
[243_tooltip.zip](http://issues.piwik.org/attachments/5663/243_tooltip.zip)

@robocoder
Copy link
Contributor

TODO: “Loading data” for swfobject isn’t centred (appears in the top left corner) in the widget.

@robocoder
Copy link
Contributor

Suggest update of swfobject should coincide with resolution of ticket #322 (update to Open Flash Chart v2).

@robocoder
Copy link
Contributor

Attachment: Forward port changes to jquery-superfish 1.4.8 and use superfish arrows
[243_superfish.zip](http://issues.piwik.org/attachments/5663/243_superfish.zip)

@robocoder
Copy link
Contributor

Updated blockUI (from 1.33 to 2.11), dimensions (from 1.1.2 to 1.2), and scrollTo (from 1.3 to 1.4) unchanged, with no apparent ill effect. I left ui.mouse, ui.sortable, and calendar alone (as there are big differences going to jquery.ui 1.5.3).

I’ll put together a patch and/or zip that rolls up all the above. If there’s no objection, I’ll probably use the YUI compressor to minify the locally modified versions of fdd2div and superfish.

@robocoder
Copy link
Contributor

Here’s the roll-up of changes:

Summary of changes:
- jQuery updated from 1.2.2 to 1.2.6
- swfobject updated from 1.5 to 2.1
- sparkline updated from upstream cvs
- fdd2div fixed to work with jQuery 1.2.6, and yuicompress’d
- tooltip updated from 1.1 to 1.3
- superfish updated from 1.4.1 to 1.4.8, and yuicompress’d
- blockUI updated from 1.33 to 2.11
- dimensions updated from 1.1.2 to 1.2
- scrollTo updated from 1.3 to 1.4

Files added:
- libs/jquery/original\ lib/fdd2div-modified.js
- libs/jquery/original\ lib/superfish_modified.js
- libs/sparkline/LICENSE-BSD.txt
- libs/sparkline/LICENSE-GPL.txt
- libs/swfobject/expressInstall.swf

Files removed:
- libs/sparkline/LICENSE
- libs/swfobject/README.txt

No change to: ui.mouse, ui.sortable, and calendar

(Attachment to follow.)

@robocoder
Copy link
Contributor

Attachment: Replaces patch for core/ViewDataTable/GenerateGraphHTML.php.
[GenerateGraphHTML.diff](http://issues.piwik.org/attachments/5663/GenerateGraphHTML.diff)

@mattab
Copy link
Member Author

mattab commented Jan 14, 2009

vipsoft, thank for the patches.

Can you please confirm, that after applying all your patches, you have tested your updated Piwik following the procedure described in http://dev.piwik.org/trac/wiki/HowToTestUI (I’ve just slightly updated it); I would recommend testing with Firefox, Internet explorer, and Safari (or Chrome): the three major web engines.

This is really important to make sure there are no regression in the UI.

@robocoder
Copy link
Contributor

I’ll let you know when I’m done testing.

@robocoder
Copy link
Contributor

Matt: I’ve had to halt testing as there’s a major regression where Dashboard changes (e.g., adding/removing/re-adding widgets) manipulates the DOM and leaves it in a bad state. I’ll continue to investigate…

To anyone else monitoring this ticket: there were some other regressions which I’ve since fixed but are not reflected in the previously attached files.

@robocoder
Copy link
Contributor

Ok, patches are on their way. I’ll also include a fix to ticket #506.

@robocoder
Copy link
Contributor

Attachment: Roll-up – contains diffs and new files
[243.zip](http://issues.piwik.org/attachments/5663/243.zip)

@pebosi
Copy link
Contributor

pebosi commented Jan 23, 2009

tried to apply the diff to my piwik installation, but patching of some files failed:

#############

patching file plugins/Dashboard/templates/Dashboard.js
patching file plugins/Dashboard/templates/widgetMenu.js
patching file plugins/UsersManager/templates/UsersManager.js
patching file plugins/CoreHome/templates/datatable.js
patching file plugins/CoreHome/templates/menu.tpl
patching file plugins/Goals/templates/single_goal.tpl
patching file core/Visualization/OpenFlashChart.php
patching file core/ViewDataTable/GenerateGraphHTML.php
Hunk #2 FAILED at 100.
1 out of 2 hunks FAILED — saving rejects to file core/ViewDataTable/GenerateGraphHTML.php.rej
patching file libs/jquery/jquery.blockUI.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/jquery/jquery.blockUI.js.rej
patching file libs/jquery/superfish_modified.js
Hunk #2 FAILED at 10.
1 out of 2 hunks FAILED — saving rejects to file libs/jquery/superfish_modified.js.rej
patching file libs/jquery/tooltip/___jquery.tooltip.js
patching file libs/jquery/tooltip/jquery.tooltip.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/jquery/tooltip/jquery.tooltip.js.rej
patching file libs/jquery/tooltip/changelog.txt
Hunk #1 FAILED at 1.
Hunk #2 FAILED at 35.
2 out of 2 hunks FAILED — saving rejects to file libs/jquery/tooltip/changelog.txt.rej
patching file libs/jquery/jquery.scrollTo.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/jquery/jquery.scrollTo.js.rej
patching file libs/jquery/jquery.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/jquery/jquery.js.rej
patching file ‘libs/jquery/original lib/jquery.blockUI.js’
patching file ‘libs/jquery/original lib/jquery.dimensions.js’
Hunk #1 FAILED at 2.
1 out of 1 hunk FAILED — saving rejects to file ‘libs/jquery/original lib/jquery.dimensions.js.rej’
patching file ‘libs/jquery/original lib/jquery.js’
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file ‘libs/jquery/original lib/jquery.js.rej’
patching file ‘libs/jquery/original lib/jquery.scrollTo.js’
Hunk #2 FAILED at 21.
1 out of 2 hunks FAILED — saving rejects to file ‘libs/jquery/original lib/jquery.scrollTo.js.rej’
patching file libs/jquery/jquery.dimensions.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/jquery/jquery.dimensions.js.rej
patching file libs/jquery/jquery.scrollTo-min.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/jquery/jquery.scrollTo-min.js.rej
patching file libs/jquery/fdd2div-modified.js
Hunk #1 FAILED at 41.
Hunk #2 FAILED at 70.
2 out of 2 hunks FAILED — saving rejects to file libs/jquery/fdd2div-modified.js.rej
patching file libs/swfobject/swfobject.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/swfobject/swfobject.js.rej
patching file libs/swfobject/README.txt
Hunk #1 FAILED at 5.
1 out of 1 hunk FAILED — saving rejects to file libs/swfobject/README.txt.rej
patching file libs/sparkline/lib/Sparkline_Bar.php
patching file libs/sparkline/lib/Sparkline_Line.php
patching file libs/sparkline/lib/Object.php
patching file libs/sparkline/lib/Sparkline.php
patching file libs/sparkline/CHANGES
patching file libs/sparkline/DESIGN
patching file libs/sparkline/README

#############

and these days jquery 1.3.1 is released.

@pebosi
Copy link
Contributor

pebosi commented Jan 23, 2009

```
patching file plugins/Dashboard/templates/Dashboard.js
patching file plugins/Dashboard/templates/widgetMenu.js
patching file plugins/UsersManager/templates/UsersManager.js
patching file plugins/CoreHome/templates/datatable.js
patching file plugins/CoreHome/templates/menu.tpl
patching file plugins/Goals/templates/single_goal.tpl
patching file core/Visualization/OpenFlashChart.php
patching file core/ViewDataTable/GenerateGraphHTML.php
Hunk #2 FAILED at 100.
1 out of 2 hunks FAILED — saving rejects to file core/ViewDataTable/GenerateGraphHTML.php.rej
patching file libs/jquery/jquery.blockUI.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/jquery/jquery.blockUI.js.rej
patching file libs/jquery/superfish_modified.js
Hunk #2 FAILED at 10.
1 out of 2 hunks FAILED — saving rejects to file libs/jquery/superfish_modified.js.rej
patching file libs/jquery/tooltip/___jquery.tooltip.js
patching file libs/jquery/tooltip/jquery.tooltip.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/jquery/tooltip/jquery.tooltip.js.rej
patching file libs/jquery/tooltip/changelog.txt
Hunk #1 FAILED at 1.
Hunk #2 FAILED at 35.
2 out of 2 hunks FAILED — saving rejects to file libs/jquery/tooltip/changelog.txt.rej
patching file libs/jquery/jquery.scrollTo.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/jquery/jquery.scrollTo.js.rej
patching file libs/jquery/jquery.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/jquery/jquery.js.rej
patching file ‘libs/jquery/original lib/jquery.blockUI.js’
patching file ‘libs/jquery/original lib/jquery.dimensions.js’
Hunk #1 FAILED at 2.
1 out of 1 hunk FAILED — saving rejects to file ‘libs/jquery/original lib/jquery.dimensions.js.rej’
patching file ‘libs/jquery/original lib/jquery.js’
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file ‘libs/jquery/original lib/jquery.js.rej’
patching file ‘libs/jquery/original lib/jquery.scrollTo.js’
Hunk #2 FAILED at 21.
1 out of 2 hunks FAILED — saving rejects to file ‘libs/jquery/original lib/jquery.scrollTo.js.rej’
patching file libs/jquery/jquery.dimensions.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/jquery/jquery.dimensions.js.rej
patching file libs/jquery/jquery.scrollTo-min.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/jquery/jquery.scrollTo-min.js.rej
patching file libs/jquery/fdd2div-modified.js
Hunk #1 FAILED at 41.
Hunk #2 FAILED at 70.
2 out of 2 hunks FAILED — saving rejects to file libs/jquery/fdd2div-modified.js.rej
patching file libs/swfobject/swfobject.js
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED — saving rejects to file libs/swfobject/swfobject.js.rej
patching file libs/swfobject/README.txt
Hunk #1 FAILED at 5.
1 out of 1 hunk FAILED — saving rejects to file libs/swfobject/README.txt.rej
patching file libs/sparkline/lib/Sparkline_Bar.php
patching file libs/sparkline/lib/Sparkline_Line.php
patching file libs/sparkline/lib/Object.php
patching file libs/sparkline/lib/Sparkline.php
patching file libs/sparkline/CHANGES
patching file libs/sparkline/DESIGN
patching file libs/sparkline/README
```

@robocoder
Copy link
Contributor

pebosi: did you “svn up” first? the diffs are against the repository (as of 882), and there was a widespread change to fix newlines per ticket #452.

@mattab
Copy link
Member Author

mattab commented Feb 3, 2009

vipsoft, is it safe now to patch Piwik? are you done with the testing? i’d like to commit asap :) thanks.

@robocoder
Copy link
Contributor

Do you want to wait for pebosi’s feedback?

I finished testing a couple of weeks ago. I already noted the issue of the swfobject “Loading data” message occasionally not being centered; I firmly expect this will self-correct itself when we move to OFC2 in ticket #322.

@pebosi
Copy link
Contributor

pebosi commented Feb 3, 2009

dont need to wait, first time i tried to patch 0.2.28, patching svn version works ;)

@robocoder
Copy link
Contributor

Matt: Having heard no complaints, it looks like this patch can be committed. Thanks.

@mattab
Copy link
Member Author

mattab commented Feb 11, 2009

guys, this is a great work! thank you for your help testing pebosi, and kudos to vipsoft for your patience and testing.

in 886

@robocoder
Copy link
Contributor

In [1548], refs #5663 - remove obsolete jquery.dimensions.js; now part of jquery.js 1.2.6

@mattab mattab added this to the RobotRock milestone Jul 8, 2014
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Major Indicates the severity or impact or benefit of an issue is much higher than normal but not critical. Task Indicates an issue is neither a feature nor a bug and it's purely a "technical" change.
Projects
None yet
Development

No branches or pull requests

4 participants