Skip to content

Commit

Permalink
docs: fix table generation (#479)
Browse files Browse the repository at this point in the history
  • Loading branch information
KiwiKilian authored Oct 28, 2024
1 parent d2d31e8 commit c9c5597
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 13 deletions.
10 changes: 2 additions & 8 deletions docs/MapView.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,10 @@
| pitchEnabled | `boolean` | `true` | `false` | Enable/Disable pitch on map |
| rotateEnabled | `boolean` | `true` | `false` | Enable/Disable rotation on map |
| attributionEnabled | `boolean` | `true` | `false` | Enable/Disable attribution on map.<br/><br/>This must be enabled for Mapbox-hosted tiles and styles. Please refer to the Mapbox Terms of Service.<br/>Other providers do not require this. |
| attributionPosition | `\| { top?: number; left?: number }
\| { top?: number; right?: number }
\| { bottom?: number; left?: number }
\| { bottom?: number; right?: number }` | `none` | `false` | Adds attribution offset, e.g. `{top: 8, left: 8}` will put attribution button in top-left corner of the map |
| attributionPosition | `{ top?: number; left?: number } \| { top?: number; right?: number } \| { bottom?: number; left?: number } \| { bottom?: number; right?: number }` | `none` | `false` | Adds attribution offset, e.g. `{top: 8, left: 8}` will put attribution button in top-left corner of the map |
| tintColor | `string \| unknown[]` | `none` | `false` | MapView's tintColor |
| logoEnabled | `boolean` | `false` | `false` | Enable/Disable the logo on the map. |
| logoPosition | `\| { top?: number; left?: number }
\| { top?: number; right?: number }
\| { bottom?: number; left?: number }
\| { bottom?: number; right?: number }` | `none` | `false` | Adds logo offset, e.g. `{top: 8, left: 8}` will put the logo in top-left corner of the map |
| logoPosition | `{ top?: number; left?: number } \| { top?: number; right?: number } \| { bottom?: number; left?: number } \| { bottom?: number; right?: number }` | `none` | `false` | Adds logo offset, e.g. `{top: 8, left: 8}` will put the logo in top-left corner of the map |
| compassEnabled | `boolean` | `none` | `false` | Enable/Disable the compass from appearing on the map |
| compassViewPosition | `number` | `none` | `false` | Change corner of map the compass starts at. 0: TopLeft, 1: TopRight, 2: BottomLeft, 3: BottomRight |
| compassViewMargins | `object` | `none` | `false` | Add margins to the compass with x and y values |
Expand Down
5 changes: 1 addition & 4 deletions docs/ShapeSource.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,7 @@
| ---- | :--: | :-----: | :------: | :----------: |
| id | `string` | `MapLibreGL.StyleSource.DefaultSourceID` | `false` | A string that uniquely identifies the source. |
| url | `string` | `none` | `false` | An HTTP(S) URL, absolute file URL, or local file URL relative to the current application’s resource bundle. |
| shape | `\| GeoJSON.GeometryCollection
\| GeoJSON.Feature
\| GeoJSON.FeatureCollection
\| GeoJSON.Geometry` | `none` | `false` | The contents of the source. A shape can represent a GeoJSON geometry, a feature, or a feature colllection. |
| shape | `GeoJSON.GeometryCollection \| GeoJSON.Feature \| GeoJSON.FeatureCollection \| GeoJSON.Geometry` | `none` | `false` | The contents of the source. A shape can represent a GeoJSON geometry, a feature, or a feature colllection. |
| cluster | `boolean` | `none` | `false` | Enables clustering on the source for point shapes. |
| clusterRadius | `number` | `none` | `false` | Specifies the radius of each cluster if clustering is enabled.<br/>A value of 512 produces a radius equal to the width of a tile.<br/>The default value is 50. |
| clusterMaxZoomLevel | `number` | `none` | `false` | Specifies the maximum zoom level at which to cluster points if clustering is enabled.<br/>Defaults to one zoom level less than the value of maxZoomLevel so that, at the maximum zoom level,<br/>the shapes are not clustered. |
Expand Down
2 changes: 1 addition & 1 deletion scripts/utils/template-globals.js
Original file line number Diff line number Diff line change
Expand Up @@ -451,7 +451,7 @@ function _propMarkdownTableRows(props, prefix = "") {
const { description = "" } = prop;
let result = `| ${prefix}${
prop.name
} | \`${type}\` | \`${defaultValue}\` | \`${
} | \`${type.replace(/^\\\| /, "").replace(/\n/g, " ")}\` | \`${defaultValue}\` | \`${
prop.required
}\` | ${replaceNewLine(description)} |`;
if (type === "shape") {
Expand Down

0 comments on commit c9c5597

Please sign in to comment.