Skip to content

Commit

Permalink
Fix plugindoc formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
manisandro committed Oct 12, 2023
1 parent 5525fd9 commit c9722b4
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 7 deletions.
6 changes: 1 addition & 5 deletions doc/plugins.md
Original file line number Diff line number Diff line change
Expand Up @@ -410,11 +410,7 @@ Allows exporting a selected portion of the map to a variety of formats.
| defaultScaleFactor | `number` | The factor to apply to the map scale to determine the initial export map scale. | `0.5` |
| dpis | `[number]` | List of dpis at which to export the map. If empty, the default server dpi is used. | `undefined` |
| exportExternalLayers | `bool` | Whether to include external layers in the image. Requires QGIS Server 3.x! | `true` |
| formatConfiguration | `{`<br />`  format: [{`<br />`  name: string,`<br />`  extraQuery: string,`<br />`  formatOptions: string,`<br />`  baseLayer: string,`<br />`}],`<br />`}` | Custom export configuration per format.
If more than one configuration per format is provided, a selection combo will be displayed.
`query` will be appended to the query string (replacing any existing parameters).
`formatOptions` will be passed as FORMAT_OPTIONS.
`baseLayer` will be appended to the LAYERS | `undefined` |
| formatConfiguration | `{`<br />`  format: [{`<br />`  name: string,`<br />`  extraQuery: string,`<br />`  formatOptions: string,`<br />`  baseLayer: string,`<br />`}],`<br />`}` | Custom export configuration per format.<br /> If more than one configuration per format is provided, a selection combo will be displayed.<br /> `query` will be appended to the query string (replacing any existing parameters).<br /> `formatOptions` will be passed as FORMAT_OPTIONS.<br /> `baseLayer` will be appended to the LAYERS | `undefined` |
| pageSizes | `[{`<br />`  name: string,`<br />`  width: number,`<br />`  height: number,`<br />`}]` | List of image sizes to offer, in addition to the free-hand selection. The width and height are in millimeters. | `[`<br />`  {name: '15 x 15 cm', width: 150, height: 150},`<br />`  {name: '30 x 30 cm', width: 300, height: 300}`<br />`]` |
| side | `string` | The side of the application on which to display the sidebar. | `'right'` |

Expand Down
2 changes: 1 addition & 1 deletion plugins/MapExport.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class MapExport extends React.Component {
* If more than one configuration per format is provided, a selection combo will be displayed.
* `query` will be appended to the query string (replacing any existing parameters).
* `formatOptions` will be passed as FORMAT_OPTIONS.
* `baseLayer` will be appended to the LAYERS */
* `baseLayer` will be appended to the LAYERS. */
formatConfiguration: PropTypes.shape({
format: PropTypes.arrayOf(PropTypes.shape({
name: PropTypes.string,
Expand Down
2 changes: 1 addition & 1 deletion scripts/gen-plugin-docs.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ pluginData.forEach(plugin => {
++documentedProps;
const defaultValue = prop.defaultValue ? prop.defaultValue.value.split("\n").map(x => '`' + x.replace(' ', ' ') + '`').join("<br />") : "`undefined`";
const type = "`" + parsePropType(prop.type).replaceAll(' ', ' ').replaceAll("\n", "`<br />`") + "`";
output += `| ${name} | ${type} | ${prop.description} | ${defaultValue} |\n`;
output += `| ${name} | ${type} | ${prop.description.replaceAll("\n", "<br />")} | ${defaultValue} |\n`;
});
if (documentedProps === 0) {
output += "|\n";
Expand Down

0 comments on commit c9722b4

Please sign in to comment.