scinote-web/app/views/shared/_inline_editing.html.erb

19 lines
867 B
Text
Raw Normal View History

<div
2019-11-12 18:26:18 +08:00
class="inline-editing-container inline-init-handler"
2019-11-03 21:59:30 +08:00
data-field-to-update="<%= config[:field_to_udpate] %>"
data-params-group="<%= config[:params_group] %>"
data-item-id="<%= config[:item_id] %>"
2019-11-03 21:59:30 +08:00
data-path-to-update="<%= config[:path_to_update] %>"
data-original-name="<%= initial_value %>"
2019-11-03 21:59:30 +08:00
data-label-after='<%= config[:label_after]&.html_safe %>'
2019-11-15 23:23:48 +08:00
data-placeholder='<%= config[:placeholder] %>'
>
2019-11-15 23:23:48 +08:00
<div class="view-mode" data-placeholder="<%= config[:placeholder] %>"><%= initial_value %></div>
<input placeholder="<%= config[:placeholder] %>" class="hidden input-field" type="text" value="<%= initial_value %>" disabled/>
<div class="button-container">
<span class="save-button"><i class="fas fa-check"></i></span>
<span class="cancel-button"><i class="fas fa-times"></i></span>
</div>
<span class="error-block"></span>
</div>