mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-25 15:16:22 +00:00
12 lines
527 B
Text
12 lines
527 B
Text
.form-check
|
|
= hidden_field_tag "#{base}[#{attribute}]", '0', id: ''
|
|
.custom-control.custom-switch
|
|
= check_box_tag "#{base}[#{attribute}]", '1', metadata.value,
|
|
class: "custom-control-input #{invalid(post, attribute)}",
|
|
aria: { describedby: id_for_help(attribute) },
|
|
autofocus: autofocus
|
|
= label_tag "#{base}_#{attribute}", post_label_t(attribute, post: post),
|
|
class: 'custom-control-label'
|
|
|
|
= render 'posts/attribute_feedback',
|
|
post: post, attribute: attribute, metadata: metadata
|