0
0
Fork 1
Spiegel von https://github.com/paviliondev/discourse-custom-wizard.git synchronisiert 2024-09-20 07:41:11 +02:00
discourse-custom-wizard/assets/javascripts/discourse/templates/components/custom-field-input.hbs

52 Zeilen
1,3 KiB
Handlebars

2020-10-20 07:40:23 +02:00
{{#if showInputs}}
<td>
{{combo-box
value=field.klass
content=klassContent
none="admin.wizard.custom_field.klass.select"
onChange=(action (mut field.klass))}}
</td>
<td>
{{combo-box
value=field.type
content=typeContent
none="admin.wizard.custom_field.type.select"
onChange=(action (mut field.type))}}
</td>
<td>
{{multi-select
value=field.serializers
content=serializerContent
none="admin.wizard.custom_field.serializers.select"
onChange=(action (mut field.serializers))}}
</td>
<td>
{{input
value=field.name
placeholder=(i18n "admin.wizard.custom_field.klass.select")}}
</td>
<td>
{{d-button action="close" icon="times"}}
</td>
{{else}}
<td><label>{{field.klass}}</label></td>
<td><label>{{field.type}}</label></td>
<td>
{{#each field.serializers as |serializer|}}
<label>{{serializer}}</label>
{{/each}}
</td>
<td><label>{{field.name}}</label></td>
<td>
{{d-button action="edit" icon="pencil-alt"}}
2020-11-09 11:44:32 +01:00
{{#if field.edit}}
{{d-button action="close" icon="times"}}
{{else}}
{{#if destroying}}
{{loading-spinner size="small"}}
{{else}}
{{d-button action="destroy" icon="trash-alt"}}
{{/if}}
{{/if}}
2020-10-20 07:40:23 +02:00
</td>
{{/if}}