Ghost/ghost/admin/app/templates/settings/design.hbs
Aileen Nowak 6945c942d0 🎨 Improved theme validation messages (#812)
closes TryGhost/Ghost#8530

- Changed the wording for activation and uploading a theme to separate between error and warnings in the title and the body text for the modal
- Changed the wording of "Activated successful with warnings/errors" to "Activation successful with (warnings || errors)"
2017-08-02 14:30:47 +04:00

82 lines
3.1 KiB
Handlebars

<section class="gh-canvas">
<header class="gh-canvas-header">
<h2 class="gh-canvas-title" data-test-screen-title>Design</h2>
<section class="view-actions">
{{gh-task-button task=save class="gh-btn gh-btn-blue gh-btn-icon" data-test-save-button=true}}
</section>
</header>
<section class="view-container">
<div class="gh-setting-header">Navigation</div>
<div class="gh-blognav-container">
<form id="settings-navigation" class="gh-blognav" novalidate="novalidate">
{{#sortable-group onChange=(action 'reorderItems') as |group|}}
{{#each model.navigation as |navItem|}}
{{gh-navitem navItem=navItem baseUrl=blogUrl addItem="addNavItem" deleteItem="deleteNavItem" updateUrl="updateUrl" group=group}}
{{/each}}
{{/sortable-group}}
{{gh-navitem navItem=newNavItem baseUrl=blogUrl addItem="addNavItem" updateUrl="updateUrl"}}
</form>
</div>
<div class="gh-setting-header">Themes</div>
<div class="gh-themes-container">
{{gh-theme-table
themes=themes
activateTheme=(action "activateTheme")
downloadTheme=(action "downloadTheme")
deleteTheme=(action "deleteTheme")}}
{{#link-to "settings.design.uploadtheme" class="gh-btn gh-btn-green gh-themes-uploadbtn" data-test-upload-theme-button=true}}
<span>Upload a theme</span>
{{/link-to}}
{{#if showDeleteThemeModal}}
{{gh-fullscreen-modal "delete-theme"
model=(hash
theme=themeToDelete
download=(action "downloadTheme" themeToDelete)
)
close=(action "hideDeleteThemeModal")
confirm=(action "deleteTheme")
modifier="action wide"}}
{{/if}}
{{#if showThemeWarningsModal}}
{{gh-fullscreen-modal "theme-warnings"
model=(hash
title="Activation successful"
warnings=themeWarnings
errors=themeErrors
message=message
canActivate=true
)
close=(action "hideThemeWarningsModal")
modifier="action wide"}}
{{/if}}
{{#if showThemeErrorsModal}}
{{gh-fullscreen-modal "theme-warnings"
model=(hash
title="Activation failed"
errors=themeErrors
fatalErrors=themeFatalErrors
canActivate=false
)
close=(action "hideThemeWarningsModal")
modifier="action wide"}}
{{/if}}
</div>
</section>
</section>
{{outlet}}
{{gh-tour-item "upload-a-theme"
target=".gh-themes-uploadbtn"
throbberAttachment="top middle"
popoverTriangleClass="bottom"
}}