app/views/hyrax/base/_show_actions.html.erb in hyrax-2.9.6 vs app/views/hyrax/base/_show_actions.html.erb in hyrax-3.0.0.pre.beta1

- old
+ new

@@ -1,43 +1,48 @@ -<div class="show-actions"> - <% if Hyrax.config.analytics? %> - <%= link_to "Analytics", presenter.stats_path, id: 'stats', class: 'btn btn-default' %> - <% end %> - <% if presenter.editor? %> +<div class="row show-actions button-row-top-two-column"> + <div class="col-sm-6"> + <% if presenter.show_deposit_for?(collections: @user_collections) %> + <input type="checkbox" style="display:none" name="batch_document_ids[]" id="batch_document_<%= presenter.id %>" value="<%= presenter.id %>" class="batch_document_selector" checked="checked" /> + <%= button_tag t('hyrax.dashboard.my.action.add_to_collection'), + class: 'btn btn-default submits-batches submits-batches-add', + data: { toggle: "modal", target: "#collection-list-container" } %> + <% end %> + <% if presenter.work_featurable? %> + <%= link_to "Feature", hyrax.featured_work_path(presenter, format: :json), + data: { behavior: 'feature' }, + class: presenter.display_unfeature_link? ? 'btn btn-default collapse' : 'btn btn-default' %> + + <%= link_to "Unfeature", hyrax.featured_work_path(presenter, format: :json), + data: { behavior: 'unfeature' }, + class: presenter.display_feature_link? ? 'btn btn-default collapse' : 'btn btn-default' %> + <% end %> + <% if Hyrax.config.analytics? %> + <%= link_to "Analytics", presenter.stats_path, id: 'stats', class: 'btn btn-default' %> + <% end %> + </div> + + <div class="col-sm-6 text-right"> + <% if presenter.editor? %> <%= link_to "Edit", edit_polymorphic_path([main_app, presenter]), class: 'btn btn-default' %> - <%= link_to "Delete", [main_app, presenter], class: 'btn btn-danger', data: { confirm: "Delete this #{presenter.human_readable_type}?" }, method: :delete %> <% if presenter.member_presenters.size > 1 %> <%= link_to t("hyrax.file_manager.link_text"), polymorphic_path([main_app, :file_manager, presenter]), class: 'btn btn-default' %> <% end %> <% if presenter.valid_child_concerns.length > 0 %> <div class="btn-group"> <button type="button" class="btn btn-default dropdown-toggle" type="button" id="dropdown-menu" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> Attach Child <span class="caret"></span></button> <ul class="dropdown-menu"> <% presenter.valid_child_concerns.each do |concern| %> <li> - <%= link_to "Attach #{concern.human_readable_type}", polymorphic_path([main_app, :new, :hyrax, :parent, concern.model_name.singular.to_sym], parent_id: presenter.id) %> + <%= link_to "Attach #{concern.human_readable_type}", polymorphic_path([main_app, :new, :hyrax, :parent, concern.model_name.singular], parent_id: presenter.id) %> </li> <% end %> </ul> </div> <% end %> - <% end %> - <% if presenter.show_deposit_for?(collections: @user_collections) %> - <input type="checkbox" style="display:none" name="batch_document_ids[]" id="batch_document_<%= presenter.id %>" value="<%= presenter.id %>" class="batch_document_selector" checked="checked" /> - <%= button_tag t('hyrax.dashboard.my.action.add_to_collection'), - class: 'btn btn-default submits-batches submits-batches-add', - data: { toggle: "modal", target: "#collection-list-container" } %> - <% end %> - <% if presenter.work_featurable? %> - <%= link_to "Feature", hyrax.featured_work_path(presenter, format: :json), - data: { behavior: 'feature' }, - class: presenter.display_unfeature_link? ? 'btn btn-default collapse' : 'btn btn-default' %> - - <%= link_to "Unfeature", hyrax.featured_work_path(presenter, format: :json), - data: { behavior: 'unfeature' }, - class: presenter.display_feature_link? ? 'btn btn-default collapse' : 'btn btn-default' %> - <% end %> + <%= link_to "Delete", [main_app, presenter], class: 'btn btn-danger', data: { confirm: "Delete this #{presenter.human_readable_type}?" }, method: :delete %> + <% end %> + </div> </div> <!-- COinS hook for Zotero --> <span class="Z3988" title="<%= export_as_openurl_ctx_kev(presenter) %>"></span> <!-- Render Modals -->