Reference · Browser table and SVG
continentViewfunction
The part of the map that frames a continent, with a margin, widened to the map's own shape so it fills the same box; the whole world for null.
Import it
import { continentView } from "@johnmorrisdotca/tenka/ui";
Definition
function continentView(key: TenkaContinentKey | null, map?: TenkaMapKey): TenkaView
Parameters
| Name | Type | Description |
|---|---|---|
key | TenkaContinentKey | null | The continent identifier, or null to show the whole map. |
map (optional) | TenkaMapKey | The native world or Europe map to use. |
Returns
TenkaView
The part of the map that frames a continent, with a margin, widened to the map's own shape so it fills the same box; the whole world for null.
Examples
import { continentView } from "@johnmorrisdotca/tenka/ui";
console.log(continentView("europe"));[ 638.219512195122, 50, 847.5609756097562, 417 ]What it prints (run when this page was built)