DataMaps

From Support Wiki
Jump to navigation Jump to search
DataMaps
Version 0.17.2
Author(s) Alex4401
Default?
NoN

The DataMaps extension lets you display interactive maps using Leaflet without additional services.

The maps can feature:

  • circular markers, pin markers, or markers with custom icons;
  • rich marker details panes with Wikitext titles, descriptions, an article link button and an image;
  • an optional coordinate display;
  • multiple switchable backgrounds;
  • "collectibles", with a checklist the user can tick things off on;
  • a search function for markers;
  • custom JS integrations.

A visual editor is in the works and will be eventually released in phases as core enablement refactorings are done.

Examples

Installation

You can request this extension to be enabled through the ticket system.

Guides / Documentation

Custom CSS/JS

To avoid loading map-specific CSS or JavaScript in every single page, the extension supports MediaWiki:DataMaps.js and MediaWiki:DataMaps.css.

Tracking categories

The extension ships with three tracking categories:

  • Pages including data maps contains all articles with included maps.
  • Pages including data maps failing validation contains all articles where a map could not be rendered successfully due to a data validation error in its source page.
  • Maps failing data validation contains all maps that failed data validation.

Configuration

$wgDataMapsNamespaceId
Identifier of the namespace that all maps will live in.
Default: managed (uses built-in namespace)
$wgDataMapsApiCaching
Since version 0.14.0.
Associative array of settings controlling API output caching.
type
Type of cache to use.
Default: CACHE_ANYTHING
ttl
Expiry time (in seconds) of cached API responses.
Default: 86400 (1 day)
ttlExtensionThreshold
Remaining time-to-live (in seconds) of cached API responses needed for the time to be extended.
Default: 43200 (12 hours)
ttlExtensionValue
Number of seconds to extend a soon-to-be-expired cached API response's life.
Default: 57600 (16 hours)
$wgDataMapsDefaultApiMarkerBatch
Number of markers the API will return by default in a single response.
Default: 2500
$wgDataMapsMaxApiMarkerBatch
Maximum number of markers an API client can request.
Default: 5000
$wgDataMapsMarkerParserExpansionLimit
Parser expansion limit used when parsing marker labels and descriptions.
Default: 800
$wgDataMapsUseInProcessParserCache
If set to true, API will use a least recently used cache (in memory of the process handling the request) when processing markers (when uncached).
Default: true
$wgDataMapsFullLinksUpdateBudget
Since version 0.14.0.
Controls total time (in seconds) that can be spent on parsing marker wikitext to perform complete links table updates.
Set to `0` to disable.
Default: 0.5
$wgDataMapsEnableCreateMap
Enables visual map creation dialog to streamline the process for users.
Since version 0.13.2.
Default: true
$wgDataMapsEnableVisualEditor
In future, this will opt wikis into the visual map editor to streamline the editing process. At the moment, this is not implemented.
This does not use the VisualEditor extension.
Since version 0.14.0.
Default: true

Translating

Translations are accepted over at translatewiki.net.

See also