Commit Graph

3 Commits

Author SHA1 Message Date
mpl 7832801040 server/camlistored/ui: on zooming/panning on map aspect, do new search
This change makes zooming and panning on the map aspect send a new
"MapSort" search query, so that the (1000, by default) most relevant
results for the currently displayed area always appear as markers
after a zoom/pan.

This required completely "lifting up" (in React lingo) the currentSearch
state out of the Header class, and into the Index class, which should
have already been done in a56372830a. This
is necessary because we need the expression in the search box to be mutable
both by the user('s input) and by the map aspect, which represents the
zoom level as a trailing "locrect" predicate in the search expression.

Fixes #938

Change-Id: I0004c9ff09f03b4f1d95a35e54605689eebf0c1a
2017-08-16 21:39:46 +02:00
mpl a56372830a server/camlistored/ui: prepare for map aspect zoom level
This change adds the logic to:
1) once a map aspect is loaded, get the area that includes all the
displayed results (the "zoom level")
2) modify the current query search predicate so that it includes the
above zoom-level as a locrect predicate
3) propagate that predicate change to the predicate that is displayed in
the search box, through the newly introduced currentSearch parameter
(a state parameter of the Index instance).

Change-Id: I955e6195ba71b2000c68c28278a534cec87f5311
2017-08-03 17:38:16 +02:00
mpl 49b97b2244 server/camlistored/ui: use search.MapSort in map aspect
Also make use of the new "locrect" search predicate, which allows us to
drop support for raw query with coordinates.

Also revert for now to using the native leaflet markers instead of the
AwesomeMarkers icons, as something in their style seems to be interfering
badly with the UI.

Fixes #934

Change-Id: Idd85eeb42673c43a216bce81c26a6bff5ad0c08a
2017-08-01 02:04:32 +02:00