Extract category name fields into a component

This commit is contained in:
Robin Ward 2018-01-08 15:08:43 -05:00
parent 74ec100aff
commit e244a1a319
2 changed files with 11 additions and 10 deletions

View File

@ -0,0 +1,10 @@
<section class='field'>
<section class="field-item">
<label>{{i18n 'category.name'}}</label>
{{text-field value=category.name placeholderKey="category.name_placeholder" maxlength="50"}}
</section>
<section class="field-item">
<label>{{i18n 'category.slug'}}</label>
{{text-field value=category.slug placeholderKey="category.slug_placeholder" maxlength="255"}}
</section>
</section>

View File

@ -1,14 +1,5 @@
<form>
<section class='field'>
<section class="field-item">
<label>{{i18n 'category.name'}}</label>
{{text-field value=category.name placeholderKey="category.name_placeholder" maxlength="50"}}
</section>
<section class="field-item">
<label>{{i18n 'category.slug'}}</label>
{{text-field value=category.slug placeholderKey="category.slug_placeholder" maxlength="255"}}
</section>
</section>
{{category-name-fields category=category tagName=""}}
{{#if canSelectParentCategory}}
<section class='field'>