Skip to content

Commit

Permalink
Documentation tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
IanHopkinson committed Feb 20, 2024
1 parent 9437a95 commit d8a5ece
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions DEMO.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,13 +90,13 @@ hdx-toolkit print --dataset_filter=wfp-food-prices-for-nigeria --with_extras
This adds resources under a `resources` key which includes a `quickcharts` key and showcases under a `showcases` key. These new keys mean that the output JSON cannot be created directly in HDX. The `fs_check_info` and `hxl_preview_config` keys which previously contained a JSON object serialised as a single string are expanded as dictionaries so that they are printed out in an easy to read format.

A Quick Chart can be uploaded from a JSON file using a commandline like where the `dataset_filter`
specifies a single dataset and the `resource_name specifies` the resource to which the Quick Chart is attached:
specifies a single dataset and the `resource_name` specifies the resource to which the Quick Chart is attached:

```
hdx-toolkit quickcharts --dataset_filter=climada-flood-dataset --hdx_site=stage --resource_name=admin1-summaries-flood.csv --hdx_hxl_preview_file_path=quickchart-flood.json
```

The hdx_hxl_preview_file_path points to a JSON format file with the key `hxl_preview_config` which
The `hdx_hxl_preview_file_path` points to a JSON format file with the key `hxl_preview_config` which
contains the Quick Chart definition. This file is converted to a single string via a temporary yaml file so should be easily readable. Example Quick Chart recipes can be found [here](https://github.com/OCHA-DAP/hxl-recipes?tab=readme-ov-file)

## Future Work
Expand Down
2 changes: 1 addition & 1 deletion tests/fixtures/quickchart-flood.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"#f2645a",
"#9C27B0"
],
"title": "Best title 1"
"title": "New title 1"
},
"dataProperties": {},
"displayCategory": "Charts",
Expand Down

0 comments on commit d8a5ece

Please sign in to comment.