-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: move datahub stats into footer (#10)
* temporary change * next fix: width * next fix: width * Fix in datahub stats margin-bottom * Fix in subscribe section stats margin-bottom * Return to former footer logo section * a bit of customization for datahub stats * a bit of customization for datahub stats * Small fix for insights.html --------- Co-authored-by: toavina <toavina@fjelltopp.org>
- Loading branch information
Showing
7 changed files
with
138 additions
and
55 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
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
22 changes: 22 additions & 0 deletions
22
ckanext/fjelltopp_theme/templates/snippets/datahub_stats.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 |
---|---|---|
@@ -0,0 +1,22 @@ | ||
{% set default_stats = h.get_datahub_stats(config_data = [{'label': 'Something else', 'value': 0}]) %} | ||
|
||
{% set stats = stats | default(default_stats) %} | ||
|
||
{% block data_rect %} | ||
<div class="data-hub-stats col-lg-6 col-sm-12 col-xs-12"> | ||
{% for i in range(0, stats|length, 2) %} | ||
<div class="row"> | ||
{% for j in range(i, i+2) %} | ||
{% if j < stats|length %} | ||
<div class="insight-small-rect col-lg-6 col-sm-6 col-xs-12"> | ||
<p>{{ stats[j]['label'] }}</p> | ||
<div class="number"> | ||
<span>{{ stats[j]['value'] }}</span> | ||
</div> | ||
</div> | ||
{% endif %} | ||
{% endfor %} | ||
</div> | ||
{% endfor %} | ||
</div> | ||
{% endblock %} |
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