Skip to content

Commit

Permalink
Improved api docs (#128)
Browse files Browse the repository at this point in the history
  • Loading branch information
kylebarron authored Oct 17, 2023
1 parent 659cb8b commit 3c0f767
Show file tree
Hide file tree
Showing 11 changed files with 223 additions and 377 deletions.
11 changes: 11 additions & 0 deletions docs/api/layers/path-layer.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# PathLayer

The `PathLayer` renders lists of coordinate points as extruded polylines with mitering.

![](../../assets/path-layer-roads.jpg)

> Screenshot from North America roads example
::: lonboard.PathLayer
options:
show_bases: false
11 changes: 11 additions & 0 deletions docs/api/layers/scatterplot-layer.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# ScatterplotLayer

The `ScatterplotLayer` renders circles at given coordinates.

![](../../assets/scatterplot-layer-network-speeds.jpg)

> Screenshot from Ookla example.
::: lonboard.ScatterplotLayer
options:
show_bases: false
19 changes: 19 additions & 0 deletions docs/api/layers/solid-polygon-layer.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# SolidPolygonLayer

The `SolidPolygonLayer` renders filled and/or extruded polygons.

```py
import geopandas as gpd
from lonboard import SolidPolygonLayer

# A GeoDataFrame with Polygon geometries
gdf = gpd.GeoDataFrame()
layer = SolidPolygonLayer.from_geopandas(
gdf,
get_fill_color=[255, 0, 0],
)
```

::: lonboard.SolidPolygonLayer
options:
show_bases: false
5 changes: 5 additions & 0 deletions docs/api/traits.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# lonboard.traits

::: lonboard.traits.ColorAccessor

::: lonboard.traits.FloatAccessor
8 changes: 2 additions & 6 deletions docs/api/top-level.md → docs/api/viz.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,8 @@

The top-level namespace accessible after `import lonboard`.

Layers are also accessible in the top-level namespace, but are documented in the `layers/` folder.

::: lonboard.viz.viz
options:
show_root_full_path: false

::: lonboard.ScatterplotLayer

::: lonboard.PathLayer

::: lonboard.SolidPolygonLayer
93 changes: 0 additions & 93 deletions docs/layers/path-layer.md

This file was deleted.

152 changes: 0 additions & 152 deletions docs/layers/scatterplot-layer.md

This file was deleted.

Loading

0 comments on commit 3c0f767

Please sign in to comment.