Skip to content

Commit

Permalink
feat: Show when an update is available
Browse files Browse the repository at this point in the history
  • Loading branch information
bradenmacdonald committed Oct 5, 2024
1 parent f54840a commit 9bb8138
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions cms/templates/studio_xblock_wrapper.html
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,18 @@
<ul class="actions-list nav-dd ui-right">
% if not is_root:
% if can_edit:
% if upstream_info and upstream_info.prompt_sync:
<li class="action-item">
<button
class="btn-default library-sync-button action-button"
title="${_("Update available - click to sync")}"
onclick="$.post('/api/contentstore/v2/downstreams/${xblock.usage_key}/sync').done(() => { location.reload(); })"
>
<span class="icon fa fa-refresh" aria-hidden="true"></span>
<span>${_("Update available")}</span>
</button>
</li>
% endif
% if use_tagging:
<li class="action-item tag-count" data-locator="${xblock.location}"></li>
% endif
Expand Down

0 comments on commit 9bb8138

Please sign in to comment.