-
-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #203 from qgis/docs-and-refactor
Docs and refactor
- Loading branch information
Showing
31 changed files
with
200 additions
and
63 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
## csv-table | ||
|
||
Can render a html table from CSV file or inner content | ||
|
||
``` | ||
{{< csv-table file="csv/schedule.csv" />}} | ||
``` | ||
|
||
![](img/csv-table.png) | ||
|
||
Example usage with inner content CSV: | ||
|
||
``` | ||
{{< csv-table >}} | ||
"LTR","Long term release, begin of new development phase" | ||
"LR","Regular release, begin of new development phase" | ||
"FF","Feature freeze, end of development phase" | ||
"PR","Point release of latest release and LTR branch" | ||
"EPR","Extra Point release" | ||
":rm-current:current",":rm-current:currently supported releases: {{< param "ltrrelease" >}} and {{< param "release" >}}" | ||
":rm-next:next",":rm-next:next releases" | ||
{{< /csv-table >}} | ||
``` | ||
|
||
Note: `param` can be used inside to substitute dynamic vars | ||
|
||
![](img/csv-table-1.png) | ||
|
||
`:rm-next:`, `:rm-current:`, etc. are transformed into CSS classes from themes/hugo-bulma-blocks-theme/assets/sass/bulma/components/roadmap.sass. Currently this shortcode is used only for roadmap tables, that's why it's called roadmap.sass |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
``` | ||
{{< download-macos >}} | ||
``` | ||
|
||
Contains links with MacOS installers |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
``` | ||
{{< download-windows >}} | ||
``` | ||
|
||
Contains links with Windows installers |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
``` | ||
{{< mobile-downloads >}} | ||
``` | ||
|
||
Contains links to mobile app downloads |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
## `param-link` Shortcode | ||
|
||
The `param-link` is different from `param` in a way that it applies `| markdownify` to its content. So the plain-text links will be rendered as clickable `<a>` tags | ||
|
||
### Parameters | ||
|
||
- `name`: The name of the configuration parameter to retrieve. | ||
|
||
### Example Usage | ||
|
||
``` | ||
Electronic document: {{< param-link "userguidecite" >}} | ||
``` | ||
|
||
^ will be rendered like `Electronic document: [https://docs.qgis.org/3.34/en/docs/developers_guide/index.html](https://docs.qgis.org/3.34/en/docs/developers_guide/index.html)` | ||
|
||
### Additional Notes | ||
Make sure that the parameter you are trying to access exists in the data/conf.json. | ||
|
||
Also see notes about automation of LT/LTR variables in the root README |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,23 @@ | ||
## `param` Shortcode | ||
|
||
The `param` shortcode is used to retrieve and display a specific configuration parameter from the site's data files. | ||
The `param` shortcode is used to retrieve and display a specific parameter from data/conf.json. This file is in sync with QGIS release schedule and contains variables related to roadmap. | ||
|
||
### Parameters | ||
|
||
- `name`: The name of the configuration parameter to retrieve. | ||
|
||
### Example Usage | ||
|
||
To use the `param` shortcode, you need to pass the name of the configuration parameter as an argument. For example, if you want to retrieve the `email` parameter from the site's configuration: | ||
|
||
```html | ||
{{< param "email" >}} | ||
``` | ||
the latest stable QGIS ({{< param "version" >}}.x {{< param "codename" >}}) | ||
``` | ||
|
||
This will output the value of the email parameter from the site's configuration data. | ||
^ will be rendered as `the latest stable QGIS (3.36.x Maidenhead)` | ||
|
||
### Additional Notes | ||
The configuration parameters are typically stored in the data directory of your Hugo site, in a file named conf.toml, conf.yaml, or conf.json. | ||
Make sure that the parameter you are trying to access exists in the site's configuration data files. | ||
This shortcode is useful for displaying dynamic content that is defined in the site's configuration and needs to be consistent across multiple pages. | ||
Make sure that the parameter you are trying to access exists in the data/conf.json. | ||
This shortcode is useful for displaying dynamic content that is defined in the site's configuration and needs to be consistent across multiple pages. | ||
|
||
The shortcode is rendered as plain text. To automatically generate a clickeble link, use `param-link` | ||
|
||
Also see notes about automation of LT/LTR variables in the root README |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
``` | ||
{{< paypal-button >}} | ||
``` | ||
|
||
inserts a button that leads to PayPal checkout |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
``` | ||
{{< script src="js/spoiler.js" >}} | ||
``` | ||
|
||
Is used to include some javascript into content file. JS files are taken from ./themes/hugo-bulma-blocks-theme/assets/js/spoiler |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
``` | ||
{{< spoiler-start id="download-bsd" title="Download for BSD" >}} | ||
[BSD Installation Instructions]({{< ref "resources/installation-guide#freebsd" >}}) | ||
{{< spoiler-end >}} | ||
``` | ||
|
||
Foldable section. May contain md, html and other shortcodes inside | ||
|
||
![](img/spoiler.png) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
``` | ||
{{< stripe-widget >}} | ||
|
||
or | ||
|
||
{{< stripe-widget otherMethods="true">}} | ||
``` | ||
|
||
Inserts a donation form integrated with Stripe. Donate options are controlled by data/stripe_products.yml | ||
|
||
![](img/stripe-widget.png) | ||
|
||
Used inside `rich-right` block: | ||
|
||
``` | ||
{{< rich-right-start >}} | ||
{{< stripe-widget otherMethods="true">}} | ||
{{< rich-right-end >}} | ||
``` | ||
|
||
`otherMethods="true"` inserts the link to /funding/donate/ page | ||
|
||
![](img/stripe-widget-1.png) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
``` | ||
{{< table-of-contents >}} | ||
``` | ||
|
||
Creates a list with links to anchor-headers from the current page. Currently used in visual changelogs | ||
|
||
![](img/table-of-contents.png) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,13 @@ | ||
## `usecase` Shortcode | ||
|
||
The `usecase` shortcode is designed to create a rich list item that links to a case study. It includes a thumbnail image, a title, and a short description. | ||
|
||
### Parameters | ||
|
||
- `thumbnail`: The filename of the thumbnail image to display. The image should be located in the `/product/case-studies/` directory. | ||
- `title`: The title of the case study. | ||
- `description`: A brief description of the case study. | ||
|
||
### Example Usage | ||
``` | ||
{{< usecase >}} | ||
``` | ||
|
||
To use the `usecase` shortcode, you need to pass the `thumbnail`, `title`, and `description` parameters like so: | ||
Creates a card with the first case study from content/product/case-studies. Currently used within `rich-right` block | ||
|
||
```html | ||
{{< usecase thumbnail="image.jpg" title="Case Study Title" description="A short description of the case study." >}} | ||
``` | ||
This will generate a rich list item with an image, title, and description that links to the specified case study. | ||
{{< rich-right-start >}} | ||
{{< usecase >}} | ||
{{< rich-right-end >}} | ||
``` | ||
|
||
### Additional Notes | ||
Ensure that the thumbnail image exists in the specified directory and is accessible. | ||
The title and description should be concise and relevant to the content of the case study they link to. | ||
This shortcode is typically used within a loop to display multiple case studies. | ||
![](img/usecase.png) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
``` | ||
{{< usecases >}} | ||
``` | ||
|
||
Creates a grid with images and links to all case studies from content/product/case-studies | ||
|
||
![](img/usecases.png) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
``` | ||
{{< visualchangelogs >}} | ||
``` | ||
|
||
Creates a list of Visual Changelogs from content/product/visual-changelogs ordered by release date. Each list item is a link to corresponding changelog page |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<div class="tile"> | ||
<a class="rich-list has-image mr-2 mb-2" href="{{ .RelPermalink }}" > | ||
<div class="image"><img src="{{ absURL "product/case-studies/" }}{{ .Params.thumbnail }}"></div> | ||
<div class="listcont ">{{.Title}}</div> | ||
</a> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 3 additions & 9 deletions
12
themes/hugo-bulma-blocks-theme/layouts/shortcodes/usecase.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,5 @@ | ||
{{ range (where .Site.Pages "Section" "product") }} | ||
{{ range (where .Pages "SectionsPath" "product/case-studies") | first 1 }} | ||
<a class="rich-list has-image mr-2 mb-2" href="{{ .RelPermalink }}" > | ||
<div class="image"><img src="{{ absURL "product/case-studies/" }}{{ .Params.thumbnail }}"></div> | ||
<div class="listcont ">{{.Title}}</div> | ||
<div class="subtext is-size-7">{{ .Params.description }}</div> | ||
</a> | ||
{{ range (where .Pages "SectionsPath" "product/case-studies") | first 1 }} | ||
{{ partial "usecase.html" . }} | ||
{{ end }} | ||
{{ end }} | ||
{{ end }} | ||
|
||
|
8 changes: 1 addition & 7 deletions
8
themes/hugo-bulma-blocks-theme/layouts/shortcodes/usecases.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,7 @@ | ||
<div class="grid"> | ||
{{ range (where .Site.Pages "Section" "product") }} | ||
{{ range (where .Pages "SectionsPath" "product/case-studies") }} | ||
<div class="tile"> | ||
<a class="rich-list has-image mr-2 mb-2" href="{{ .RelPermalink }}" > | ||
<div class="image"><img src="{{ .Params.thumbnail }}"></div> | ||
<div class="listcont ">{{.Title}}</div> | ||
<!--div class="subtext is-size-7">{{ .Params.date }}</div--> | ||
</a> | ||
</div> | ||
{{ partial "usecase.html" . }} | ||
{{ end }} | ||
{{ end }} | ||
</div> |