Small CSS fixes for permissions [SCI-6207] (#3638)

Co-authored-by: Anton <anton@scinote.net>
This commit is contained in:
aignatov-bio 2021-11-09 09:26:22 +01:00 committed by GitHub
parent f11a4701d0
commit d3e178e5a2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 46 additions and 14 deletions

View file

@ -216,7 +216,7 @@ var dropdownSelector = (function() {
if (config.customDropdownIcon) {
return config.customDropdownIcon();
}
return '<i class="fas fa-caret-down right-icon"></i><i class="fas fa-search right-icon"></i>';
return '<i class="fas fa-caret-down right-icon"></i><i class="fas fa-search right-icon simple-dropdown"></i>';
}
// Set new data

View file

@ -0,0 +1,12 @@
#user_assignments_modal {
.modal-body {
max-height: 400px;
overflow: auto;
}
.sci-input-container {
.fa-search {
color: $color-alto;
}
}
}

View file

@ -336,13 +336,11 @@
}
.my-module-user-tags {
.tag-label {
padding: 5px;
}
img {
border-radius: 50%;
display: inline;
margin: 5px;
margin-right: .5em;
max-height: 20px;
max-width: 20px;
}

View file

@ -420,9 +420,14 @@
.update-repository-record-modal {
.rows-list-container {
display: flex;
display: grid;
grid-template-columns: 1fr;
margin: 0 -10px;
&.multiple {
grid-template-columns: 1fr 1fr;
}
.header {
font-weight: bold;

View file

@ -45,7 +45,7 @@
top: 8px;
width: 18px;
&.fa-search {
&.fa-search.simple-dropdown {
color: $brand-focus;
display: none;
}

View file

@ -713,6 +713,7 @@ ul.double-line > li {
.badge-indicator {
background: $brand-primary;
border-radius: $border-radius-tag;
color: $color-white;
font-size: 10px;
margin-left: -8px;

View file

@ -12,8 +12,9 @@
</div>
<%= form_with(model: form_object, url: create_path, method: :post, remote: true, html: { id: 'new-user-assignment-to-project-form', data: { action: 'replace-form', target: '#user_assignments_modal' } }) do |f| %>
<div class="modal-body">
<div class="form-group">
<%= text_field_tag :search_users, '', placeholder: t('.find_people_html'), class: 'form-control', data: { action: 'filter-list', target: 'new-user-assignment-to-project-form' } %>
<div class="sci-input-container left-icon">
<%= text_field_tag :search_users, '', placeholder: t('.find_people_html'), class: 'sci-input-field', data: { action: 'filter-list', target: 'new-user-assignment-to-project-form' } %>
<i class="fas fa-search"></i>
</div>
<% f.object.resource_members.each do |member| %>
<%= f.fields_for :resource_members, member do |member_form| %>

View file

@ -25,6 +25,20 @@
class: 'move-experiment'%>
</li>
<% end %>
<!-- Set or view user experiment assignments -->
<% if can_manage_experiment_users?(experiment) %>
<li>
<%= link_to edit_access_permissions_project_experiment_path(project, experiment), data: { action: 'remote-modal'} do %>
<span><%= t('experiments.index.experiment_access') %></span>
<% end %>
</li>
<% else %>
<li>
<%= link_to access_permissions_project_experiment_path(project, experiment), data: { action: 'remote-modal'} do %>
<span><%= t('experiments.index.experiment_access') %></span>
<% end %>
</li>
<% end %>
<% if can_archive_experiment?(experiment) %>
<li><%= link_to t('experiments.archive.label_title'),
archive_experiment_url(experiment),

View file

@ -24,7 +24,7 @@
<% else %>
<p class="description"><%= t('my_modules.modals.update_repository_record.message', size: selected_rows.values.count) %></p>
<% end %>
<div class="rows-list-container">
<div class="rows-list-container <%= 'multiple' if rows_to_assign.values.any? && rows_to_unassign.values.any? %>">
<% if rows_to_assign.values.any? %>
<div class="rows-to-assign">
<p class="header">

View file

@ -53,7 +53,7 @@
<template id="my-module-repository-full-view-update-button">
<button type="button" class="btn btn-primary assign-button" id="updateRepositoryRecords" disabled>
<%= t('general.update') %>
<%= t('repositories.update_records_to_module') %>
</button>
</template>

View file

@ -1018,7 +1018,7 @@ en:
assign_repository_record:
title: 'Assign %{repository_name} items to task %{my_module_name}'
title_downstream: 'Assign %{repository_name} items to task and downstream'
message: You will assign %{size} items to this task only are you ready to assign them?
message: You will assign %{size} items to this task only. Are you ready to assign them?
message_downstream: You will assign %{size} items to the following tasks. Are you ready to assign them?
current_task: "Current task"
hidden_tasks: "No permission: There are %{size} tasks you cant assign to."
@ -1460,7 +1460,8 @@ en:
restore_record: "Restore"
save_record: "Save"
cancel_save: "Cancel"
assign_records_to_module: "Assign"
assign_records_to_module: "Assign to task"
update_records_to_module: "Update task"
unassign_records_from_module: "Unassign"
columns: "Columns"
column_new_text: "New column"
@ -2521,7 +2522,7 @@ en:
submit: "Grant access"
submit_singular: "Grant access to 1 user"
submit_plural: "Grant access to {num} users"
find_people_html: "&#128269; Find people"
find_people_html: "Find people"
projects:
modals:
show_modal: