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

Timeslider++ #2070

Closed
wants to merge 76 commits into from
Closed

Timeslider++ #2070

wants to merge 76 commits into from

Conversation

marcelklehr
Copy link
Contributor

These are my fixes for @s1341's new timeslider (see #2040).

The first commit essentially introduces a new path calculator that computes a path from one revision to a new one (early version of that here: https://gist.github.com/marcelklehr/8208237), the rest of the changes are collateral to this: I stripped out partialTransition for example and reduced some other parts, too.

My second commit addresses #2065 as well as the OccupyChar issue. I hope it doesn't cause any bugs, accidentally.

Lastly, there are still a few soar spots in the timeslider codez that should be addresses (e.g. try going from rev#36 to rev#25, i think), so.. NOT READY yet.

Update: see below...

s1341 added 30 commits December 17, 2013 17:35
This commit introduces a new TimesliderClient object which will
eventually handle all communication with the server in a sane fashion.

At the moment, minimal work has been done to wire the existing code into
this object. The current 'on("MESSAGE_TYPE")' model will change so that
the timeslider object is actually the one managing all the information,
instead of delegating it all out to callbacks.

This current version still works just as the stock version did.
The slider handle and stars render correctly. Not yet wired up to real
events.
without this, the timeslider and sliderui classes don't work
Working slider class with mouse handling (click, drag) and events
(change, slide). Lots of console logs still in the code.

Got rid of some of the legacy code.
Also, the steppers actually work.
findPath works. transition requests changesets from server. processing
of changesets works correctly.

Only need to manage the async-ifying of transition, which is currently
written as a while loop, (with a short-circuit break for debugging).
There are still some weird kinks in the traversal algorithm. For
example, trying to go from 9 -> 19 fails very oddly.
There are still some bugs in the traversal algorithm, as well
as bugs being triggered in the server. Also, for some reason it looks
like there is a problem with the attribute pool not containing certain
elements.
Working:
  - location.hash
  - click on slider
  - stepper buttons
  - UI update (except authors)
Not working:
  - playback
  - bugs in transition code
@marcelklehr
Copy link
Contributor Author

There are (and have been for quite a while) some problems with the timeslider in the master branch. This (as well as #2040) is a complete re-implementation of the timeslider. All bugs mentioned in this thread refer to the version proposed here. ;)

@marcelklehr
Copy link
Contributor Author

http://ricostacruz.com/nprogress/ might be nice to have since loading is apparently quite slow.

@marcelklehr
Copy link
Contributor Author

I would very much appreciate some help right now. Please have a go at testing this everyone (use attributes like lists and stuff), and please help sort out why they're not displayed correctly. Thank you!

@JohnMcLear
Copy link
Member

Bug1) Revision 0 doesn't show the initial pad contents. To replicate:

  • Create a new pad
  • Type additional content
  • Create 5 or so revisions.

Revision 0 is incorrect.

Bug 2) Play doesn't work
Hitting play on a pad with 20 revisions does nothing (no error etc), data does display in console. Hitting pause twice starts the pad playing fine.

@marcelklehr
Copy link
Contributor Author

  1. Long story (see Add assertions for the results of CHANGESET_REQ #2054) tl;dr: There are different rev counts. I tried to to avoid getting insane about them and chose to deal with one only. The result is that rev0 is '\n' in the timeslider (however, rev0 in the db is the result of applying _cs_0 on '\n'). I don't know if my current approach is a good idea, but it works.

  2. This is probably because I changed the play button to always play, so if it arrives at the end it'll just keep playing. Rationale: Hit play and see edits in real-time as they happen on the pad.

@JohnMcLear JohnMcLear self-assigned this Nov 15, 2014
@JohnMcLear
Copy link
Member

The UX is really broken but the functionaltiy seems pretty solid. @0ip @luto did you guys wanna look at the UI/X on this and get it tight? Note the UI has been heavily modified since so you will want to rebase onto develop.

@JohnMcLear
Copy link
Member

@marcelklehr the version 0 is still showing nothing. Why not just do an if content == "" show rev1 instead of rev0?

@JohnMcLear
Copy link
Member

/tests/frontend/?grep=timeslider_labels.js and /tests/frontend/?grep=timeslider_revisions.js fail -- I will sort these.

@JohnMcLear
Copy link
Member

There is no ability to export a given revision any more.

There is no button to go back to the pad.

Is this expected behavior @marcelklehr ?

@JohnMcLear
Copy link
Member

The test it("jumps to a revision given in the url", function(done) { fails intentionally as it attempt to get teh contents at rev0 which is currently incorrect as per #2070 (comment)

This with some work will be ready to merge :)

@JohnMcLear JohnMcLear removed their assignment Nov 15, 2014
@JohnMcLear
Copy link
Member

@marcelklehr I rebased this so bugfixing for you should be easier :)

@marcelklehr
Copy link
Contributor Author

the timeslider bar is gone now, is that intentional? Also, something's messing up the attributes, I can't wrap my head around this right now

@JohnMcLear
Copy link
Member

Yeah the bar gone is intentional until we figure out a good ui,ux

@JohnMcLear
Copy link
Member

Closing as it's been neglected.. I dunno if @marcelklehr wants to take this on again, doesn't seem that way!

@JohnMcLear JohnMcLear closed this Mar 31, 2015
@marcelklehr
Copy link
Contributor Author

marcelklehr commented Apr 2, 2015 via email

@JohnMcLear
Copy link
Member

No worries :)

@muxator muxator deleted the refactor-timeslider branch April 26, 2020 21:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants