#7559 closed defect (fixed)
expand_dir.js is buggy on table layouts
Reported by: | Pedro Algarvio, aka, s0undt3ch | Owned by: | Christian Boos |
---|---|---|---|
Priority: | normal | Milestone: | 0.11.6 |
Component: | version control/browser | Version: | 0.12dev |
Severity: | normal | Keywords: | |
Cc: | Martin.vGagern@… | Branch: | |
Release Notes: | |||
API Changes: | |||
Internal Changes: |
Description
When creating a custom template to trac I found out that expand_dir.js show's buggy behaviour on table layouts.
When looking for parents, the script should only use the first one found, not all parents()
.
Here's a patch:
-
trac/htdocs/js/expand_dir.js
40 40 41 41 // handler for click event on the expander icons 42 42 window.toggleDir = function(expander, qargs) { 43 var tr = expander.parents("tr ");43 var tr = expander.parents("tr:first"); 44 44 var folderid = tr.get(0).id; 45 45 46 46 if ( tr.filter(".expanded").length ) { // then *fold*
Yes, I know table layouts should be avoided, but that's not the issue here, the issue is making the script work better/as expected.
Attachments (0)
Change History (6)
comment:1 by , 16 years ago
Owner: | set to |
---|
comment:2 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Suggested fix applied in r7543.
comment:3 by , 15 years ago
Cc: | added |
---|
How about the expander.parents("td") in the fetch part of the function? I guess that this should receive the same treatment.
Are there any plans to merge this fix into 0.11-stable?
comment:4 by , 15 years ago
Resolution: | fixed |
---|---|
Status: | closed → reopened |
The milestone says 0.11.2, but apparently this was only committed on trunk.
comment:5 by , 15 years ago
Milestone: | 0.11.2 → 0.11.6 |
---|---|
Resolution: | → fixed |
Status: | reopened → closed |
Requested again in #7634…