Toggle menu
49
33
34
2.2K
Landrace.Wiki - The Landrace Cannabis Wiki
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

MediaWiki talk:Common.js: Difference between revisions

Discussion page of MediaWiki:Common.js
No edit summary
No edit summary
Line 1: Line 1:
{{TalkHeader}}
{{TalkHeader}}
{{TalkBox
{{TalkBox
|title=Purpose
|title=Purpose
|body=Coordination + change tracking for [[MediaWiki:Common.js]] (site-wide JavaScript).
|body=Coordination + change tracking for [[MediaWiki:Common.js]] (site-wide JavaScript). Keep implementation on the JS page. Use this page for tasks, regression notes, and decisions.
}}
}}
{{TalkBox
{{TalkBox
|title=Current Status
|title=Current Libraries
|body=
|body=
* '''Libraries:''' Leaflet 1.9.4, MarkerCluster 1.4.1, Turf.js 6
* Leaflet 1.9.4
* '''Features:''' Clustering, hull generation, 3 base layers, status-colored markers
* Leaflet.markercluster 1.4.1
* '''Last major update:''' 2026-01-13
* Turf.js 6
}}
}}
{{TalkBox
{{TalkBox
|title=Known Issues
|title=Known issues / watchlist
|body=
|body=
* Hulls not displaying — need 3+ accessions per Growing Area (data issue, not code)
* Fullscreen expand button — not yet functional
* Fullscreen expand button — not yet functional
* Hulls require 3+ accessions per Growing Area to display
* Region labels removed (were overlapping with sparse data)
}}
{{TalkBox
|title=Open tasks
|body=
* [ ] Fix fullscreen map overlay
* [ ] Side panel navigation (click area → filtered accession list)
* [ ] Add a small "Discuss" link/button to key infoboxes (later)
}}
}}


Line 24: Line 29:


=== 2026-01-13 ===
=== 2026-01-13 ===
* Added Turf.js hull generation for Growing Area boundaries
; Marker clustering
* Removed permanent labels hover/click only
* '''Change:''' Added Leaflet.markercluster with worst-status bubble-up
* '''Reason:''' Visual clutter with sparse data
* '''Reason:''' Overlapping pins at zoomed-out view
* '''Result:''' Clusters show count + color of worst status inside
 
; Hull boundaries
* '''Change:''' Added Turf.js auto-generated convex/concave hulls for Growing Areas
* '''Reason:''' Visual indication of area coverage without manual GeoJSON
* '''Result:''' Dashed polygons appear at zoom 6-12, colored by worst status
 
; Hull buffer
* '''Change:''' Added 3km buffer around all hulls
* '''Reason:''' Linear accession distributions created thin/weird shapes
* '''Result:''' Capsule-shaped boundaries that look like proper areas
 
; Labels removed
* '''Change:''' Removed permanent region/area labels, kept hover tooltips only
* '''Reason:''' Visual clutter with sparse/clustered data
* '''Result:''' Cleaner map, area info on hover/click
 
; Satellite layer
* '''Change:''' Added Esri World Imagery as third base layer option
* '''Reason:''' Useful for seeing actual terrain/cultivation areas
* '''Result:''' 3-button toggle (basic/terrain/satellite)


=== 2026-01-12 ===
=== 2026-01-12 ===
* Added marker clustering with worst-status bubble-up
; CSV URL encoding fix
* Added satellite base layer
* '''Change:''' Added encoding for dashes (-2D) and colons (-3A) in buildCSVUrl()
* Fixed CSV URL encoding for dashes/colons in accession IDs
* '''Reason:''' Accession IDs with dashes/colons broke SMW CSV export URLs
* '''Reason:''' Main page map not displaying pins
* '''Result:''' Maps display pins correctly


== Decisions ==
== Decisions ==
; Auto-generated hulls vs manual GeoJSON
; Auto-generated hulls vs manual GeoJSON (2026-01-13)
: Chose auto-generated — updates automatically, dashed style signals "approximate"
: Chose auto-generated — updates automatically as accessions added, dashed style communicates "approximate"
 
; Interaction-only labels (2026-01-13)
: Removed permanent labels — too cluttered with sparse data, hover tooltips sufficient


; Interaction-only labels
; 3km hull buffer (2026-01-13)
: Removed permanent labels — clutter reduction, tooltips sufficient
: Prevents linear point distributions from creating thin unusable polygons

Revision as of 10:35, 13 January 2026

Talk

Discussion for: MediaWiki:Common.js ViewLinksRelated changes

Use this page for verification notes, disputes, and action items. Keep narrative content on the article.

Purpose
Coordination + change tracking for MediaWiki:Common.js (site-wide JavaScript). Keep implementation on the JS page. Use this page for tasks, regression notes, and decisions.
Current Libraries
* Leaflet 1.9.4
  • Leaflet.markercluster 1.4.1
  • Turf.js 6
Known issues / watchlist
* Fullscreen expand button — not yet functional
  • Hulls require 3+ accessions per Growing Area to display
  • Region labels removed (were overlapping with sparse data)
Open tasks
* [ ] Fix fullscreen map overlay
  • [ ] Side panel navigation (click area → filtered accession list)
  • [ ] Add a small "Discuss" link/button to key infoboxes (later)

Changelog

2026-01-13

Marker clustering
  • Change: Added Leaflet.markercluster with worst-status bubble-up
  • Reason: Overlapping pins at zoomed-out view
  • Result: Clusters show count + color of worst status inside
Hull boundaries
  • Change: Added Turf.js auto-generated convex/concave hulls for Growing Areas
  • Reason: Visual indication of area coverage without manual GeoJSON
  • Result: Dashed polygons appear at zoom 6-12, colored by worst status
Hull buffer
  • Change: Added 3km buffer around all hulls
  • Reason: Linear accession distributions created thin/weird shapes
  • Result: Capsule-shaped boundaries that look like proper areas
Labels removed
  • Change: Removed permanent region/area labels, kept hover tooltips only
  • Reason: Visual clutter with sparse/clustered data
  • Result: Cleaner map, area info on hover/click
Satellite layer
  • Change: Added Esri World Imagery as third base layer option
  • Reason: Useful for seeing actual terrain/cultivation areas
  • Result: 3-button toggle (basic/terrain/satellite)

2026-01-12

CSV URL encoding fix
  • Change: Added encoding for dashes (-2D) and colons (-3A) in buildCSVUrl()
  • Reason: Accession IDs with dashes/colons broke SMW CSV export URLs
  • Result: Maps display pins correctly

Decisions

Auto-generated hulls vs manual GeoJSON (2026-01-13)
Chose auto-generated — updates automatically as accessions added, dashed style communicates "approximate"
Interaction-only labels (2026-01-13)
Removed permanent labels — too cluttered with sparse data, hover tooltips sufficient
3km hull buffer (2026-01-13)
Prevents linear point distributions from creating thin unusable polygons