mirror of
https://github.com/discourse/discourse.git
synced 2026-07-29 23:58:12 -05:00
UX: display info about extra files and uploader (#9595)
Co-authored-by: David Taylor <david@taylorhq.com>
This commit is contained in:
co-authored by
David Taylor
parent
0d84f3afd4
commit
45f704906d
@@ -31,6 +31,7 @@ export default Controller.extend({
|
||||
availableComponentsNames: mapBy("availableChildThemes", "name"),
|
||||
availableActiveComponentsNames: mapBy("availableActiveChildThemes", "name"),
|
||||
childThemesNames: mapBy("model.childThemes", "name"),
|
||||
extraFiles: filterBy("model.theme_fields", "target", "extra_js"),
|
||||
|
||||
@discourseComputed("model.editedFields")
|
||||
editedFieldsFormatted() {
|
||||
|
||||
@@ -126,6 +126,15 @@
|
||||
</span>
|
||||
{{/if}}
|
||||
</div>
|
||||
{{else}}
|
||||
<div class="control-unit">
|
||||
<span class="heading">{{i18n "admin.customize.theme.creator"}}</span>
|
||||
<span>
|
||||
{{#user-link user=model.user}}
|
||||
{{format-username model.user.username}}
|
||||
{{/user-link}}
|
||||
</span>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
{{#unless model.component}}
|
||||
@@ -219,6 +228,24 @@
|
||||
{{#d-button action=(action "addUploadModal") class="btn-default" icon="plus"}}{{i18n "admin.customize.theme.add"}}{{/d-button}}
|
||||
</div>
|
||||
|
||||
{{#if extraFiles.length}}
|
||||
<div class="control-unit">
|
||||
<div class="mini-title">{{i18n "admin.customize.theme.extra_files"}}</div>
|
||||
<div class="description">
|
||||
{{#if model.remote_theme}}
|
||||
{{i18n "admin.customize.theme.extra_files_remote"}}
|
||||
{{else}}
|
||||
{{i18n "admin.customize.theme.extra_files_upload"}}
|
||||
{{/if}}
|
||||
</div>
|
||||
<ul>
|
||||
{{#each extraFiles as |extraFile|}}
|
||||
<li>{{extraFile.name}}</li>
|
||||
{{/each}}
|
||||
</ul>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
{{#if hasSettings}}
|
||||
<div class="control-unit">
|
||||
<div class="mini-title">{{i18n "admin.customize.theme.theme_settings"}}</div>
|
||||
|
||||
Reference in New Issue
Block a user