okfn / timeliner

[DEPRECATED] See new TimeMapper repo https://github.com/okfn/timemapper
https://github.com/okfn/timemapper
93 stars 21 forks source link

Timeline and Map events are connected #36

Closed rufuspollock closed 11 years ago

rufuspollock commented 11 years ago

Clicking on map highlights item in timeline and vice-versa.

Implementation

om-design commented 11 years ago

Could you use a hyperlink to send a POST event ?

om-design commented 11 years ago

wacky workaround.. use smaller icon images for the map, give every point an icon with a unique name, then, in-cache or on server, switch the image and/or scale the size for that point when selected in the timeline.

djw commented 11 years ago

As far as I can see, the only way that TimelineJS allows you to navigate between markers is via onhashchange. The goToMarker method exists, but is not exposed, even in the latest version of Timeline.

But that might work quite well... The URL would represent the currently selected marker, and we could make the map listen to onhashchange, and update the URL when a marker is clicked. That'd give us the two-way communication.

The only downside I can see is that shared URLs take with them the user's current selection.

What do you think, @rgrp ?

djw commented 11 years ago

37 is relevant here

rufuspollock commented 11 years ago

@djw I think this is great and would also solve #37. Please dive in and start coding it up ;-)