mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
ENHANCEMENT: open/7886 added preview button to the settings page so that when a user changes the theme they can preview the change.
This commit is contained in:
parent
5768e421dc
commit
ad7383a58d
@ -124,7 +124,7 @@
|
||||
canPreview: function() {
|
||||
var contentEl = this.getLayoutContainer().find('.cms-content');
|
||||
// Only load if we're in the "edit page" view
|
||||
var blockedClasses = ['CMSPagesController', 'CMSSettingsController', 'CMSPageHistoryController'];
|
||||
var blockedClasses = ['CMSPagesController', 'CMSPageHistoryController'];
|
||||
return !(contentEl.is('.' + blockedClasses.join(',.')));
|
||||
},
|
||||
|
||||
|
@ -0,0 +1,5 @@
|
||||
<div class="cms-navigator">
|
||||
<a href="#" class="ss-ui-button cms-preview-toggle-link" data-icon="preview">
|
||||
« <% _t('SilverStripeNavigator.Edit', 'Edit') %>
|
||||
</a>
|
||||
</div>
|
Loading…
x
Reference in New Issue
Block a user