discourse/app/assets/javascripts/wizard/addon/templates/components/wizard-step.hbs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

75 lines
2.3 KiB
Handlebars
Raw Normal View History

<div class="wizard-step-contents">
{{#if this.step.title}}
<h1 class="wizard-step-title">{{this.step.title}}</h1>
{{/if}}
<div class={{this.bannerAndDescriptionClass}}>
{{#if this.bannerImage}}
<img src={{this.bannerImage}} class="wizard-step-banner">
{{/if}}
{{#if this.step.description}}
<p class="wizard-step-description">{{html-safe this.step.description}}</p>
{{/if}}
</div>
<WizardStepForm @step={{this.step}}>
{{#if this.includeSidebar}}
<div class="wizard-fields-sidebar">
{{#each this.step.fields as |field|}}
{{#if field.show_in_sidebar}}
<WizardField @field={{field}} @step={{this.step}} @wizard={{this.wizard}} />
{{/if}}
{{/each}}
</div>
{{/if}}
<div class="wizard-fields-main">
{{#each this.step.fields as |field|}}
{{#unless field.show_in_sidebar}}
<WizardField @field={{field}} @step={{this.step}} @wizard={{this.wizard}} />
{{/unless}}
{{/each}}
</div>
</WizardStepForm>
</div>
2016-08-25 13:14:56 -04:00
<div class="wizard-step-footer">
2016-09-20 14:04:18 -04:00
2016-08-25 13:14:56 -04:00
<div class="wizard-progress">
2016-09-20 14:04:18 -04:00
<div class="white"></div>
<div style={{this.barStyle}} class="black"></div>
2016-09-20 14:04:18 -04:00
<div class="screen"></div>
<span>{{bound-i18n "wizard.step" current=this.step.displayIndex total=this.wizard.totalSteps}}</span>
2016-08-25 13:14:56 -04:00
</div>
<div class="wizard-buttons">
{{#if this.showQuitButton}}
<a href {{action "quit"}} tabindex="11" class="action-link quit">{{i18n "wizard.quit"}}</a>
{{/if}}
{{#if this.showFinishButton}}
<button {{action "exitEarly"}} disabled={{this.saving}} tabindex="10" type="button" class="wizard-btn finish">
{{i18n "wizard.finish"}}
</button>
{{/if}}
{{#if this.showBackButton}}
<a href {{action "backStep"}} tabindex="11" class="action-link back">{{i18n "wizard.back"}}</a>
{{/if}}
2016-08-25 13:14:56 -04:00
{{#if this.showNextButton}}
<button {{action "nextStep"}} disabled={{this.saving}} tabindex="10" type="button" class="wizard-btn next primary">
{{i18n "wizard.next"}}
{{d-icon "chevron-right"}}
</button>
{{/if}}
{{#if this.showDoneButton}}
<button {{action "quit"}} disabled={{this.saving}} tabindex="10" type="button" class="wizard-btn done">
{{i18n "wizard.done"}}
</button>
{{/if}}
</div>
2016-08-25 13:14:56 -04:00
</div>