2019-08-13 19:09:23 +00:00
|
|
|
.form-group{ class: invalid(post, attribute) }
|
|
|
|
= label_tag "post_#{attribute}", post_label_t(attribute, post: post)
|
2019-08-16 23:25:07 +00:00
|
|
|
|
|
|
|
.taggable{ data: { values: metadata.value.join(','),
|
|
|
|
name: "post[#{attribute}][]", list: id_for_datalist(attribute),
|
|
|
|
remove: 'false', legend: post_label_t(attribute, post: post),
|
|
|
|
described: id_for_help(attribute) } }
|
|
|
|
|
|
|
|
= text_field(*field_name_for('post', attribute, '[]'),
|
|
|
|
value: metadata.value.join(', '),
|
|
|
|
**field_options(attribute, metadata))
|
|
|
|
|
2019-08-13 19:09:23 +00:00
|
|
|
= render 'posts/attribute_feedback',
|
|
|
|
post: post, attribute: attribute, metadata: metadata
|
2019-08-16 23:25:07 +00:00
|
|
|
|
|
|
|
%datalist{ id: id_for_datalist(attribute) }
|
|
|
|
- site.everything_of(attribute).each do |value|
|
|
|
|
%option{ value: value }
|