Browse Source

Fix for focus and error reporting

development
Godwin 8 years ago
parent
commit
6781b41e04
  1. 7
      app/assets/stylesheets/_application.scss
  2. 8
      app/controllers/application_controller.rb
  3. 7
      app/views/shared/_navbar.html.haml

7
app/assets/stylesheets/_application.scss

@ -2340,14 +2340,9 @@ html[data-lingua-franca-example="html"] {
.select-field select:focus, .select-field select:focus,
.workshop-link:focus .title, .workshop-link:focus .title,
#main-nav .nav a:focus .title { #main-nav .nav a:focus .title {
html & {
outline: 0.25rem solid rgba($colour-2, 0);
outline-offset: 0.2rem;
@include _(transition, outline 150ms ease-in-out);
}
html[data-input="kb"] & { html[data-input="kb"] & {
outline: 0.25rem solid rgba($colour-2, 0.5); outline: 0.25rem solid rgba($colour-2, 0.5);
outline-offset: 0.2rem;
z-index: 1; z-index: 1;
} }
} }

8
app/controllers/application_controller.rb

@ -160,9 +160,15 @@ class ApplicationController < LinguaFrancaApplicationController
current_user, current_user,
).deliver_now if Rails.env.preview? || Rails.env.production? ).deliver_now if Rails.env.preview? || Rails.env.production?
# log the error
logger.info exception.to_s
logger.info exception.backtrace.join("\n")
# show the error page # show the error page
error_500 exception error_500 exception
raise exception
# raise the error if we are in development so that we can debug it
raise exception if Rails.env.development?
end end
def generate_confirmation(user, url, expiry = nil) def generate_confirmation(user, url, expiry = nil)

7
app/views/shared/_navbar.html.haml

@ -1,5 +1,6 @@
%nav %nav
#main-nav #main-nav
- begin
= row(class: 'inner-nav') do = row(class: 'inner-nav') do
- if logged_in? - if logged_in?
= columns(medium: 12, class: 'user-nav') do = columns(medium: 12, class: 'user-nav') do
@ -14,10 +15,12 @@
= columns(medium: 8, class: 'nav') do = columns(medium: 8, class: 'nav') do
= nav_link :about = nav_link :about
= nav_link :policy = nav_link :policy
- case (@conference ? @conference.registration_status.to_sym : :closed) - case (@conference && @conference.registration_status ? @conference.registration_status.to_sym : :closed)
- when :pre - when :pre
= nav_link register_path(@conference.slug), :pre_register, :register = nav_link register_path(@conference.slug), :pre_register, :register
- when :open - when :open
= nav_link register_path(@conference.slug), :register = nav_link register_path(@conference.slug), :register
- else - else
= render 'shared/donate_button', :email_address => (@conference.paypal_email_address || @conference.email_address || @conference.organizations.first.email_address) = render 'shared/donate_button', :email_address => (@conference.paypal_email_address || @conference.email_address || (@conference.organizations.present? && @conference.organizations.first.present? ? @conference.organizations.first.email_address : nil))
- rescue
Loading…
Cancel
Save