1
0
Fork 0
discourse-custom-wizard-unl.../assets/javascripts/discourse/templates/components/wizard-custom-input.hbs
2020-03-24 20:35:46 +11:00

55 Zeilen
1,3 KiB
Handlebars

{{#if options.hasOutput}}
<div class="connector prefix">
{{combo-box
value=input.type
content=inputTypes}}
</div>
{{/if}}
{{#if hasPairs}}
<div class="input-pairs">
{{#each input.pairs as |pair|}}
{{wizard-custom-input-pair
pair=pair
last=pair.last
inputType=inputType
keyPlaceholder=keyPlaceholder
valuePlaceholder=valuePlaceholder
userFields=userFields
wizardFields=wizardFields
options=options
removePair=(action 'removePair')}}
{{/each}}
{{#if options.hasOutput}}
<a {{action 'addPair'}} class="add-pair">
{{d-icon 'plus'}}
</a>
{{/if}}
</div>
{{/if}}
{{#if options.hasOutput}}
{{#if hasOutputConnector}}
<div class="connector">
<span class="output-connector">
{{outputConnector}}
</span>
</div>
{{/if}}
<div class="output input-block">
{{wizard-custom-input-selector
selectorType='output'
inputType=inputType
userFields=userFields
wizardFields=wizardFields
value=input.output
activeType=input.output_type
customPlaceholder=outputPlaceholder
options=options}}
</div>
{{/if}}
<a class="remove-input" {{action remove input}}>
{{d-icon 'times'}}
</a>