mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-28 10:08:20 -05:00
57 lines
2.1 KiB
Handlebars
57 lines
2.1 KiB
Handlebars
|
|
<div class='content-list span6'>
|
|
<h3>{{i18n admin.customize.long_title}}</h3>
|
|
<ul>
|
|
{{#each model}}
|
|
<li><a {{action selectStyle this}} {{bindAttr class="this.selected:active"}}>{{this.description}}</a></li>
|
|
{{/each}}
|
|
</ul>
|
|
<button {{action newCustomization}} class='btn'>{{i18n admin.customize.new}}</button>
|
|
</div>
|
|
|
|
|
|
{{#if selectedItem}}
|
|
<div class='current-style'>
|
|
<div class='admin-controls'>
|
|
<ul class="nav nav-pills">
|
|
<li {{bindAttr class="view.stylesheetActive:active"}}>
|
|
<a {{action selectStylesheet href="true" target="view"}}>{{i18n admin.customize.css}}</a>
|
|
</li>
|
|
<li {{bindAttr class="view.headerActive:active"}}>
|
|
<a {{action selectHeader href="true" target="view"}}>{{i18n admin.customize.header}}</a>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
|
|
{{#with selectedItem}}
|
|
{{textField class="style-name" value=name}}
|
|
{{#if view.headerActive}}
|
|
{{view Discourse.AceEditorView contentBinding="header" mode="html"}}
|
|
{{/if}}
|
|
{{#if view.stylesheetActive}}
|
|
{{view Discourse.AceEditorView contentBinding="stylesheet" mode="css"}}
|
|
{{/if}}
|
|
{{/with}}
|
|
<br>
|
|
<div class='status-actions'>
|
|
<span>{{i18n admin.customize.override_default}} {{view Ember.Checkbox checkedBinding="selectedItem.override_default_style"}}</span>
|
|
<span>{{i18n admin.customize.enabled}} {{view Ember.Checkbox checkedBinding="selectedItem.enabled"}}</span>
|
|
{{#unless selectedItem.changed}}
|
|
<a class='preview-link' {{bindAttr href="selectedItem.previewUrl"}} target='_blank'>{{i18n admin.customize.preview}}</a>
|
|
|
|
|
<a href="/?preview-style=" target='_blank'>{{i18n admin.customize.undo_preview}}</a><br>
|
|
{{/unless}}
|
|
</div>
|
|
|
|
<div class='buttons'>
|
|
<button {{action save}} {{bindAttr disabled="selectedItem.disableSave"}} class='btn'>{{i18n admin.customize.save}}</button>
|
|
<span class='saving'>{{selectedItem.savingStatus}}</span>
|
|
<a {{action destroy}} class='delete-link'>{{i18n admin.customize.delete}}</a>
|
|
</div>
|
|
|
|
</div>
|
|
{{else}}
|
|
<p class="about">{{i18n admin.customize.about}}</p>
|
|
{{/if}}
|
|
<div class='clearfix'></div>
|
|
|