X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/blobdiff_plain/eb65410e7520e6d09130a8591d886595219d73e4..decb7051f6436aedfd0e9de934d149d9c5b22b36:/doc/todo/provide_inline_diffs_in_recentchanges.mdwn?ds=sidebyside diff --git a/doc/todo/provide_inline_diffs_in_recentchanges.mdwn b/doc/todo/provide_inline_diffs_in_recentchanges.mdwn index fe7eb1014..3bf1bdc33 100644 --- a/doc/todo/provide_inline_diffs_in_recentchanges.mdwn +++ b/doc/todo/provide_inline_diffs_in_recentchanges.mdwn @@ -1,3 +1,5 @@ +[[!template id=gitbranch branch=anarcat/inline_diffs author="[[anarcat]]"]] + It would rock if I could view diffs from the web without going via feeds. I envision toggle-style buttons on the recentchanges page, or just links to the CGI, which then displays the diff... --[[madduck]] > The diffs are actually there, enabled by the [[plugins/recentchangesdiff]] @@ -5,25 +7,21 @@ It would rock if I could view diffs from the web without going via feeds. I envi > You might try a user stylesheet with `div.diff { display: block }`. > --[[JasonBlevins]] -> > couldn't the diff be displayed as a popup? right now it's too bad because the diff is actually in the page, generated and downloaded, but the user can't see it. I have tried to address the issue by adding stuff to the change.tmpl template, but I may be missing something - and it doesn't quite look right: -> > -> > --- /usr/share/ikiwiki/templates/change.tmpl 2011-09-05 15:14:19.000000000 -0400 -> > +++ templates/change.tmpl 2011-10-11 13:04:37.704346964 -0400 -> > @@ -39,6 +39,7 @@ -> > -> > -> > -> > +[[show diff|wikiicons/diff.png]] -> >
-> >
-> >      
-> > 
-> > There are a few things wrong with this:
+> > I have implemented this in a branch in my repository (see the side box).
 > > 
-> >  1. I don't like the hardcoded javascript in there, we should use [[plugins/toggle]] or something, but i am not sure how to make the this plugin depend on toggle, or if it is desirable. 
-> >  2. it doesn't work at all: first it doesn't actually "toggle" and second the javascript somehow gets filtered out of the resulting HTML so we don't even see it
-> >  3. if the diffurl parameter is set in the template, we'd actually see two sets of glasses, which is silly. i tried moving the diff button upwards into the PAGES loop, but there the diffurls are file-specific, which also seem quite silly
+> > Unfortunately it has some issues:
 > > 
-> > I am looking for guidance on how to improve and fix this now. --[[anarcat]] 2011-10-11
+> > 1. it assumes the toggle.js code is loaded somehow - now loaded manually
+> > 2. if the toggle code isn't loaded the diffs are displayed (which is arguably better than showing nothing since we ship the diff to the UA anyways...) - i actually think that's fine
+> > 3. it will show only if there's a revert URL, which is backwards, but otherwise the display is weird, with each button on its own line fixed!
+> > 4. if the diffurl parameter is set in the template, we'd actually see two sets of glasses, which is silly. - just added a tmp_unless to fix this.
+> >
+> > I feel this should nevertheless be implemented because if we're going to compile all this crap in the page anyways and send it to the client, why not allow the user to show it? I also feel that showing it by default is a lesser evil for non-javascript users.
+> >
+> > -- [[anarcat]] 2012-03-03
+
+> > > I have pushed a new version of this patch to my branch, which fixes all the above issues. I think this is ready to be merged now. -- [[anarcat]] 2012-07-19
+
+>>>> [[done]] --[[Joey]] 
 
-[[!tag wishlist]]
+[[!tag wishlist patch]]