diff --git a/app/assets/javascripts/sitewide/avatar_modal.js b/app/assets/javascripts/sitewide/avatar_modal.js index 893ed0c64..7859c54d1 100644 --- a/app/assets/javascripts/sitewide/avatar_modal.js +++ b/app/assets/javascripts/sitewide/avatar_modal.js @@ -31,7 +31,7 @@ var avatarsModal = (function() { reader.readAsDataURL(inputField.files[0]); reader.onload = function() { var avatarContainer = $(modal).find('.avatar-preview-container'); - $(modal).find('.save-button').removeClass('disabled'); + $(modal).find('.save-button').removeClass('disabled').attr('disabled', false); $(modal).find('#new_avatar').val(reader.result); avatarContainer.show().children().remove(); @@ -50,7 +50,7 @@ var avatarsModal = (function() { function initPredefinedAvatars() { $(modal).find('.avatar-collection .avatar').click(function() { - $(modal).find('.save-button').removeClass('disabled'); + $(modal).find('.save-button').removeClass('disabled').attr('disabled', false); $(modal).find('#raw_avatar')[0].value = null; $(modal).find('.avatar-preview-container').hide(); $(modal).find('.current-avatar').show().find('img') @@ -63,7 +63,7 @@ var avatarsModal = (function() { $(modal).find('.save-button').click(function() { if ($(this).hasClass('disabled')) return; - $(this).addClass('disabled'); + $(this).addClass('disabled').attr('disabled', true); $.ajax({ url: $(modal).data('update-url'), type: 'PUT', @@ -76,7 +76,7 @@ var avatarsModal = (function() { location.reload(); }, error: () => { - $(this).removeClass('disabled'); + $(this).removeClass('disabled').attr('disabled', false); } }); }); diff --git a/app/assets/stylesheets/global_activities.scss b/app/assets/stylesheets/global_activities.scss index e6a949b3b..1ef49cded 100644 --- a/app/assets/stylesheets/global_activities.scss +++ b/app/assets/stylesheets/global_activities.scss @@ -34,22 +34,6 @@ display: flex; height: 42px; - .hide-actions { - align-items: center; - color: $color-silver-chalice; - display: flex; - margin-right: 20px; - - &:hover { - text-decoration: none; - } - - .fas { - font-size: 18px; - margin-right: 5px; - } - } - .ga-search-container { display: none; flex-grow: 1; diff --git a/app/assets/stylesheets/protocol_management.scss b/app/assets/stylesheets/protocol_management.scss index a11303793..67573f78c 100644 --- a/app/assets/stylesheets/protocol_management.scss +++ b/app/assets/stylesheets/protocol_management.scss @@ -226,6 +226,7 @@ align-items: center; display: flex; height: 30px; + margin-top: 5px; .info-line.button { flex-grow: 1; @@ -355,15 +356,6 @@ } } - .external-import-btn { - background-color: $brand-primary; - border: 0; - color: $color-white; - font-size: 12px; - padding-bottom: 3px; - padding-top: 3px; - } - .footer { background: $color-white; bottom: -30px; diff --git a/app/assets/stylesheets/shared_styles/constants/fonts.scss b/app/assets/stylesheets/shared_styles/constants/fonts.scss index 0ba864524..0517b6b69 100644 --- a/app/assets/stylesheets/shared_styles/constants/fonts.scss +++ b/app/assets/stylesheets/shared_styles/constants/fonts.scss @@ -6,40 +6,40 @@ $font-family-base: $font-family-lato; $font-family-icons: "Font Awesome 5 Free"; $font-size-base: 16px; +$font-fas-check: "\f00c"; +$font-fas-exclamation-triangle: "\f071"; @mixin font-h1 { - font-family: $font-family-base; font-size: 24px; font-weight: bold; } @mixin font-h2 { - font-family: $font-family-base; font-size: 18px; font-weight: bold; } @mixin font-h3 { - font-family: $font-family-base; font-size: $font-size-base; font-weight: bold; } @mixin font-main { - font-family: $font-family-base; font-size: $font-size-base; } @mixin font-button { - font-family: $font-family-base; font-size: 14px; } @mixin font-small { - font-family: $font-family-base; font-size: 12px; } +@mixin font-awesome { + font-family: "Font Awesome 5 Free"; + font-weight: 501; +} diff --git a/app/assets/stylesheets/shared_styles/elements/buttons.scss b/app/assets/stylesheets/shared_styles/elements/buttons.scss index 446dda727..c7d5e4e0e 100644 --- a/app/assets/stylesheets/shared_styles/elements/buttons.scss +++ b/app/assets/stylesheets/shared_styles/elements/buttons.scss @@ -9,11 +9,11 @@ color: $color-white; cursor: pointer; display: inline-block; - font-size: 14px; line-height: 20px; outline: 0; padding: 7px 16px; position: relative; + text-align: center; text-decoration: none; transition: .3s; user-select: none; @@ -36,7 +36,7 @@ } &:focus { - border: $border-focus; + box-shadow: 0 0 0 1px $brand-focus; color: $color-white; outline: 0; text-decoration: none; @@ -60,7 +60,7 @@ } &:focus { - border: $border-focus; + box-shadow: 0 0 0 1px $brand-focus; color: $color-black; } } @@ -83,7 +83,7 @@ } &:focus { - border: $border-focus; + box-shadow: 0 0 0 1px $brand-focus; color: $color-black; } } @@ -101,7 +101,7 @@ } &:focus { - border: $border-focus; + box-shadow: 0 0 0 1px $brand-focus; color: $color-white; } } @@ -146,7 +146,7 @@ .sci-btn { float: left; - margin: 0 4px 4px 0; + margin: 2px 4px 2px 0; &:nth-last-child(1) { margin-right: 0; diff --git a/app/assets/stylesheets/shared_styles/elements/checkboxes.scss b/app/assets/stylesheets/shared_styles/elements/checkboxes.scss index 311a58139..c7cee3baa 100644 --- a/app/assets/stylesheets/shared_styles/elements/checkboxes.scss +++ b/app/assets/stylesheets/shared_styles/elements/checkboxes.scss @@ -23,15 +23,14 @@ input[type="checkbox"].sci-checkbox { width: var(--sci-checkbox-size); &::before { + @include font-awesome; animation-timing-function: $timing-function-sharp; background: $color-white; border: $border-default; border-radius: 1px; color: $color-white; content: ""; - font-family: "Font Awesome 5 Free"; font-size: calc(var(--sci-checkbox-size) - var(--sci-checkbox-size) * .375); - font-weight: 501; height: var(--sci-checkbox-size); left: 0; line-height: calc(var(--sci-checkbox-size) - 2px); @@ -51,7 +50,7 @@ input[type="checkbox"].sci-checkbox { &::before { background: $brand-primary; border: 1px solid $brand-primary; - content: "\f00c"; + content: $font-fas-check; } } diff --git a/app/assets/stylesheets/shared_styles/elements/input_fields.scss b/app/assets/stylesheets/shared_styles/elements/input_fields.scss index 29b584bfa..c86571b5d 100644 --- a/app/assets/stylesheets/shared_styles/elements/input_fields.scss +++ b/app/assets/stylesheets/shared_styles/elements/input_fields.scss @@ -40,7 +40,6 @@ } &.left-icon { - .sci-input-field { padding: 0 0 0 30px; } @@ -51,7 +50,6 @@ } &.right-icon { - .sci-input-field { padding: 0 30px 0 10px; } @@ -63,15 +61,13 @@ &.success, &.error { - .sci-input-field { padding: 0 30px 0 10px; } &::after { + @include font-awesome; bottom: 0; - font-family: "Font Awesome 5 Free"; - font-weight: 501; line-height: 36px; position: absolute; right: 5px; @@ -93,7 +89,7 @@ &.success { &::after { color: $brand-success; - content: "\f00c"; + content: $font-fas-check; } } @@ -104,7 +100,7 @@ &::after { color: $brand-danger; - content: "\f071"; + content: $font-fas-exclamation-triangle; } &::before { diff --git a/app/assets/stylesheets/shared_styles/elements/radio_buttons.scss b/app/assets/stylesheets/shared_styles/elements/radio_buttons.scss index 0536573ae..706e8a12e 100644 --- a/app/assets/stylesheets/shared_styles/elements/radio_buttons.scss +++ b/app/assets/stylesheets/shared_styles/elements/radio_buttons.scss @@ -28,9 +28,7 @@ input[type="radio"].sci-radio { border-radius: 50%; color: $color-white; content: ""; - font-family: "Font Awesome 5 Free"; font-size: calc(var(--sci-radio-size) - var(--sci-radio-size) * .375); - font-weight: 501; height: var(--sci-radio-size); left: 0; line-height: calc(var(--sci-radio-size) - 2px); diff --git a/app/assets/stylesheets/themes/main_navigation.scss b/app/assets/stylesheets/themes/main_navigation.scss index 888adb874..2a42b27ff 100644 --- a/app/assets/stylesheets/themes/main_navigation.scss +++ b/app/assets/stylesheets/themes/main_navigation.scss @@ -43,6 +43,10 @@ align-items: center; display: flex; padding: 0 15px; + + #logo { + max-height: 22px; + } } .dropdown-notifications { @@ -392,10 +396,6 @@ #search-bar { padding-right: 0; - - .btn-default[type="submit"] { - height: 34px; - } } @media (max-width: 768px) { diff --git a/app/assets/stylesheets/themes/scinote.scss b/app/assets/stylesheets/themes/scinote.scss index 0aceee0de..57fb236e3 100644 --- a/app/assets/stylesheets/themes/scinote.scss +++ b/app/assets/stylesheets/themes/scinote.scss @@ -1855,6 +1855,14 @@ th.custom-field .modal-tooltiptext { color: $color-white; font: bold; } + + .res-description { + color: $color-white; + } + + .res-type { + border-color: $color-white; + } } ul { diff --git a/app/views/global_activities/_top_pane.html.erb b/app/views/global_activities/_top_pane.html.erb index e7c06eb6c..7c1ca2073 100644 --- a/app/views/global_activities/_top_pane.html.erb +++ b/app/views/global_activities/_top_pane.html.erb @@ -2,12 +2,14 @@ <%= t('activities.index.global_activities_title') %>
- - <%= t('activities.index.expand_all') %> - - - <%= t('activities.index.collapse_all') %> - +
+ + <%= t('activities.index.expand_all') %> + + + <%= t('activities.index.collapse_all') %> + +
diff --git a/app/views/my_module_tags/_index_edit.html.erb b/app/views/my_module_tags/_index_edit.html.erb index 6f698cbc0..d33ff05c1 100644 --- a/app/views/my_module_tags/_index_edit.html.erb +++ b/app/views/my_module_tags/_index_edit.html.erb @@ -61,7 +61,7 @@ :name, {}, { class: 'selectpicker' }) %> - <%= f.button class: 'btn btn-primary' do %> + <%= f.button class: 'sci-btn' do %> <% end %>
@@ -73,7 +73,7 @@ <%= f.hidden_field :project_id, :value => @my_module.experiment.project.id %> <%= f.hidden_field :name, :value => t("tags.create.new_name") %> <%= f.hidden_field :color, :value => Constants::TAG_COLORS[0] %> - <%= f.button class: "btn btn-primary" do %> + <%= f.button class: "sci-btn" do %> <% end %> diff --git a/app/views/my_modules/modals/_manage_module_tags_modal.html.erb b/app/views/my_modules/modals/_manage_module_tags_modal.html.erb index 94f977386..f9489c83a 100644 --- a/app/views/my_modules/modals/_manage_module_tags_modal.html.erb +++ b/app/views/my_modules/modals/_manage_module_tags_modal.html.erb @@ -7,7 +7,7 @@
diff --git a/app/views/protocol_importers/_preview_modal_footer.html.erb b/app/views/protocol_importers/_preview_modal_footer.html.erb index 6a05e76a8..98e1ef60a 100644 --- a/app/views/protocol_importers/_preview_modal_footer.html.erb +++ b/app/views/protocol_importers/_preview_modal_footer.html.erb @@ -1,3 +1,3 @@ - - - + + + diff --git a/app/views/protocol_importers/_protocol_card.html.erb b/app/views/protocol_importers/_protocol_card.html.erb index ef6d1cc1d..95ef4c9b8 100644 --- a/app/views/protocol_importers/_protocol_card.html.erb +++ b/app/views/protocol_importers/_protocol_card.html.erb @@ -19,7 +19,7 @@
<% if show_import_button %> - + <% end %>
diff --git a/app/views/steps/_step.html.erb b/app/views/steps/_step.html.erb index a3a936db2..4f1ac4cce 100644 --- a/app/views/steps/_step.html.erb +++ b/app/views/steps/_step.html.erb @@ -29,25 +29,25 @@ <% if (can_manage_protocol_in_module?(@protocol) || can_manage_protocol_in_repository?(@protocol)) && !(preview) %> " data-remote="true"> " data-remote="true"> " href="<%= edit_step_path(step, format: :json) %>" data-remote="true" > - <%= link_to(step_path(step), title: t("protocols.steps.options.delete_title"), method: "delete", class: "btn btn-link", + <%= link_to(step_path(step), title: t("protocols.steps.options.delete_title"), method: "delete", class: "sci-btn tertiary icon-btn", data: {action: "delete-step", confirm: t("protocols.steps.destroy.confirm", step: step.name)}) do %> <% end %> diff --git a/app/views/user_my_modules/_index_edit.html.erb b/app/views/user_my_modules/_index_edit.html.erb index c5c384454..3297ab003 100644 --- a/app/views/user_my_modules/_index_edit.html.erb +++ b/app/views/user_my_modules/_index_edit.html.erb @@ -43,7 +43,7 @@ <%= collection_select(:user_my_module, :user_id, @unassigned_users, :id, :full_name, {}, { class: 'selectpicker' }) %>
- <%= f.button class: 'btn btn-primary' do %> + <%= f.button class: 'btn sci-btn' do %> <% end %> diff --git a/app/views/user_projects/_index_edit.html.erb b/app/views/user_projects/_index_edit.html.erb index a36cdc599..682502c18 100644 --- a/app/views/user_projects/_index_edit.html.erb +++ b/app/views/user_projects/_index_edit.html.erb @@ -68,7 +68,7 @@
- <%= f.button class: 'btn btn-primary' do %> + <%= f.button class: 'sci-btn' do %> <% end %> diff --git a/app/views/users/confirmations/new.html.erb b/app/views/users/confirmations/new.html.erb index 16650b5ec..a6279097e 100644 --- a/app/views/users/confirmations/new.html.erb +++ b/app/views/users/confirmations/new.html.erb @@ -12,7 +12,7 @@
- <%= f.submit t("devise.confirmations.new.submit"), class: "btn btn-primary" %> + <%= f.submit t("devise.confirmations.new.submit"), class: "sci-btn" %>
<% end %> diff --git a/app/views/users/invitations/edit.html.erb b/app/views/users/invitations/edit.html.erb index b42d97458..38f46f199 100644 --- a/app/views/users/invitations/edit.html.erb +++ b/app/views/users/invitations/edit.html.erb @@ -47,7 +47,7 @@ <%= recaptcha_input_tag %>
- <%= f.submit "Sign Up", class: "btn btn-primary" %> + <%= f.submit "Sign Up", class: "sci-btn" %>
<% end %> diff --git a/app/views/users/passwords/edit.html.erb b/app/views/users/passwords/edit.html.erb index e56470524..0e968afaa 100644 --- a/app/views/users/passwords/edit.html.erb +++ b/app/views/users/passwords/edit.html.erb @@ -27,7 +27,7 @@
- <%= f.submit t("devise.passwords.edit.submit"), class: "btn btn-primary" %> + <%= f.submit t("devise.passwords.edit.submit"), class: "sci-btn" %>
<% end %> diff --git a/app/views/users/passwords/new.html.erb b/app/views/users/passwords/new.html.erb index 4598aa0e4..dcf4afaa5 100644 --- a/app/views/users/passwords/new.html.erb +++ b/app/views/users/passwords/new.html.erb @@ -17,7 +17,7 @@
- <%= f.submit t("devise.passwords.new.submit"), class: "btn btn-primary" %> + <%= f.submit t("devise.passwords.new.submit"), class: "sci-btn" %>
<% end %> diff --git a/app/views/users/registrations/new.html.erb b/app/views/users/registrations/new.html.erb index 40137c451..0bc6a5fc8 100644 --- a/app/views/users/registrations/new.html.erb +++ b/app/views/users/registrations/new.html.erb @@ -43,7 +43,7 @@ <%= recaptcha_input_tag %>
- <%= f.submit 'Sign up', class: 'btn btn-primary' %> + <%= f.submit 'Sign up', class: 'sci-btn' %>
<% end %> diff --git a/app/views/users/registrations/new_with_provider.html.erb b/app/views/users/registrations/new_with_provider.html.erb index bf95d3de5..286befed6 100644 --- a/app/views/users/registrations/new_with_provider.html.erb +++ b/app/views/users/registrations/new_with_provider.html.erb @@ -16,7 +16,7 @@ <% end %>
- <%= f.submit 'Sign up', class: 'btn btn-primary' %> + <%= f.submit 'Sign up', class: 'sci-btn' %>
<% end %> diff --git a/app/views/users/sessions/new.html.erb b/app/views/users/sessions/new.html.erb index 245e51f83..e3b78836b 100644 --- a/app/views/users/sessions/new.html.erb +++ b/app/views/users/sessions/new.html.erb @@ -28,7 +28,7 @@ <%= hidden_field_tag(:simple_sign_in, @simple_sign_in) %>
- <%= f.submit t("devise.sessions.new.submit"), class: "btn btn-primary" %> + <%= f.submit t("devise.sessions.new.submit"), class: "sci-btn" %>
<% end %> diff --git a/app/views/users/shared/_user_avatars_modal.html.erb b/app/views/users/shared/_user_avatars_modal.html.erb index d1e73dc4f..de00b295a 100644 --- a/app/views/users/shared/_user_avatars_modal.html.erb +++ b/app/views/users/shared/_user_avatars_modal.html.erb @@ -32,7 +32,7 @@ diff --git a/app/views/users/unlocks/new.html.erb b/app/views/users/unlocks/new.html.erb index 14b5b313e..c4f4e1348 100644 --- a/app/views/users/unlocks/new.html.erb +++ b/app/views/users/unlocks/new.html.erb @@ -17,7 +17,7 @@
- <%= f.submit t("devise.unlocks.new.submit"), class: "btn btn-primary" %> + <%= f.submit t("devise.unlocks.new.submit"), class: "sci-btn" %>
<% end %> diff --git a/public/images/scinote_icon.svg b/public/images/scinote_icon.svg index 365899717..a50cd9114 100644 --- a/public/images/scinote_icon.svg +++ b/public/images/scinote_icon.svg @@ -1,5 +1,5 @@ - - - - + + + +