Sha256: 1f246abb6c83d5d2986e14cd6d93d6d34ddafb166f156a13105bdcff5ade6e31
Contents?: true
Size: 1.85 KB
Versions: 3
Compression:
Stored size: 1.85 KB
Contents
<%- input_classes = ['input yarii-cloudinary--text-input'] input_classes << className if local_assigns[:className] name = name_from_variable(local_assigns) value = value_from_variable(local_assigns) %> <div data-controller="cloudinary-single-media" data-cloudinary-single-media-cloud="<%= ENV['yarii_cloudinary_cloud_name'] %>" <% if ENV['yarii_cloudinary_tag'] -%>data-cloudinary-single-media-upload-preset="<%= ENV['yarii_cloudinary_tag'] %>"<% end -%> data-cloudinary-single-media-browse-path="<%= yarii_cloudinary.media_path %>" data-cloudinary-single-media-form-thumbnail-path="<%= yarii_cloudinary.form_thumbnail_medium_path(0) %>" class="yarii-cloudinary--field field" > <label class="label"><%= label %></label> <div class="control"> <div class="level"> <div class="level-item is-narrow"> <div data-target="cloudinary-single-media.thumbnail"> <% if value.present? %> <%= render 'yarii_cloudinary/media/form_thumbnail', public_id: value %> <% else %> <span class="icon is-medium has-text-info"><i class="fa fa-picture-o fa-lg"></i></span> <% end %> </div> </div> <div class="level-item"> <%= content_tag :input, nil, name: name, value: value, class: input_classes.join(' '), type: 'text', placeholder: placeholder, data: {target: 'cloudinary-single-media.input'} %> </div> <div class="level-item is-narrow"> <button data-action="cloudinary-single-media#open" class="button is-primary"> <span class="icon"><i class="fa fa-upload"></i></span> <span>Upload</span> </button> <button data-action="cloudinary-single-media#browse" class="button is-success"> <span class="icon"><i class="fa fa-picture-o"></i></span> <span>Browse</span> </button> </div> </div> </div> </div>
Version data entries
3 entries across 3 versions & 1 rubygems