Skip to content

Commit

Permalink
feat: add a warning about unindexed tweets
Browse files Browse the repository at this point in the history
  • Loading branch information
andylolz committed Aug 8, 2024
1 parent 7556ce9 commit 3faf721
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions output/_layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,14 @@
</header>

{% if site.data.meta.total_tweets == 0 %}
<div class="alert alert-danger" role="alert">
<strong>Something’s gone wrong.</strong> There are currently no notes to show. We’re investigating.
</div>
<div class="alert alert-danger" role="alert">
<strong>Something’s gone wrong.</strong> There are currently no notes to show. We’re investigating.
</div>
{% elsif site.data.meta.total_fetched < site.data.meta.total_tweets %}
{% assign perc_fetched = site.data.meta.total_fetched | times: 100 | divided_by: site.data.meta.total_tweets %}
<div class="alert alert-warning" role="alert">
<strong>Warning: Only {{ perc_fetched }}% of tweets are currently indexed.</strong> Unindexed tweets are not included in search or filtering.
</div>
{% endif %}

<main>
Expand Down

0 comments on commit 3faf721

Please sign in to comment.