Liking cljdoc? Tell your friends :D

cljs-map-pins.core

The cljs-map-pins core namespace.

The cljs-map-pins core namespace.
raw docstring

add-controls!cljs

(add-controls! m {controls :controls})

Adds passed OpenLayers ol.control.Control instances to the given map.

Adds passed OpenLayers ol.control.Control instances to the given map.
raw docstring

create-featurecljs

(create-feature {coords :coordinates img :img :as feature})

Creates a ol.Feature instance from the feature map. It assigns the ol.geom.Point instance with the feature coordinates and ol.style.Style instance with the ol.style.Icon for the given feature image path.

Creates a ol.Feature instance from the feature map. It assigns the ol.geom.Point
instance with the feature coordinates and ol.style.Style instance with the
ol.style.Icon for the given feature image path.
raw docstring

draw-pins!cljs

(draw-pins! map-element ol-options features handlers)

Draws a map in the passed HTML element. The element must have non-zero width and height for the map to show. Takes a map of Open Layers options and passes it to the ol.Map instance. Draws all the features from the features vector and assigns the appropriate handlers from the handlers map. Throws an exception if any of the parameters don't match their respective Schema.

Draws a map in the passed HTML element. The element must have non-zero
width and height for the map to show. Takes a map of Open Layers options
and passes it to the ol.Map instance. Draws all the features from the features
vector and assigns the appropriate handlers from the handlers map.
Throws an exception if any of the parameters don't match their respective
Schema.
raw docstring

feature-event-handlercljs

(feature-event-handler handlers)

Returns an event-handling function that will be called by OpenLayers when a feature is clicked on the map. The function will retrieve a FeatureHandler instance that is mapped to the feature type keyword and execute its handling function. If there are no feature for the type executes the default handler.

Returns an event-handling function that will be called by OpenLayers
when a feature is clicked on the map. The function will retrieve a
FeatureHandler instance that is mapped to the feature type keyword
and execute its handling function. If there are no feature for the type
executes the default handler.
raw docstring

FeatureHandlercljsprotocol

Protocol describing the behavior of a map feature on-click handler.

Protocol describing the behavior of a map feature on-click handler.

handlecljs

(handle this feature)
raw docstring

Featurescljs

A Schema describing the map of features that will be drawn on the map.

A Schema describing the map of features that will be drawn on the map.
raw docstring

features-valid?cljs

(features-valid? features)

A function asserting the validity of map features map against the Features Schema.

A function asserting the validity of map features map against the Features Schema.
raw docstring

Handlerscljs

A Schema describing the map of map feature handlers. There can be as many handlers as there are feature types with additional two handlers: one default and one used when there are no features in the on-click event.

A Schema describing the map of map feature handlers. There can be as many
handlers as there are feature types with additional two handlers: one default
and one used when there are no features in the on-click event.
raw docstring

handlers-valid?cljs

(handlers-valid? handlers)

A function validating the feature handlers map against the Handlers Schema.

A function validating the feature handlers map against the Handlers Schema.
raw docstring

map-on-click-handler!cljs

(map-on-click-handler! map {noop :no-feature :as handlers})

Creates an on-click event handler and assigns it to the map. Calls the feature-event-handler function when there is a feature on the clicked pixel otherwise executes the no-op handler supplied in the handlers map.

Creates an on-click event handler and assigns it to the map.
Calls the feature-event-handler function when there is a feature on
the clicked pixel otherwise executes the no-op handler supplied in the
handlers map.
raw docstring

map-on-feature-pointer-handler!cljs

(map-on-feature-pointer-handler! m map-element)

Creates an event handler and assigns it to the map. It will change the pointer style to 'hand' when mouse crosses over a feature on the map.

Creates an event handler and assigns it to the map.
It will change the pointer style to 'hand'
when mouse crosses over a feature on the map.
raw docstring

ol-options-valid?cljs

(ol-options-valid? ol-options)

A function asserting the validity of OpenLayers options against OLOpts Schema.

A function asserting the validity of OpenLayers options against OLOpts Schema.
raw docstring

OLOptscljs

A Schema describing the OpenLayers options map used for map drawing. This is direct copy from here: https://openlayers.org/en/latest/apidoc/module-ol_View-View.html

A Schema describing the OpenLayers options map used for map drawing.
This is direct copy from here: https://openlayers.org/en/latest/apidoc/module-ol_View-View.html
raw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close