diff --git a/app/assets/javascripts/footer_modal.js b/app/assets/javascripts/footer_modal.js new file mode 100644 index 000000000..28d02804f --- /dev/null +++ b/app/assets/javascripts/footer_modal.js @@ -0,0 +1,5 @@ +document.addEventListener("turbolinks:load", () => { + if (window.location.hash == "#sponsors") { + $('#sponsors').modal('show'); + } +}); diff --git a/app/views/main/_sponsors.html.erb b/app/views/main/_sponsors.html.erb new file mode 100644 index 000000000..298612e94 --- /dev/null +++ b/app/views/main/_sponsors.html.erb @@ -0,0 +1,111 @@ +

+ <%= t('sponsors.sponsorships') %> +

+
+ <%= t('sponsors.uni_hd') %> +
+ +
+ <%= t('sponsors.hse') %> +
+ + + \ No newline at end of file diff --git a/app/views/main/sponsors.html.erb b/app/views/main/sponsors.html.erb deleted file mode 100644 index 6302bba28..000000000 --- a/app/views/main/sponsors.html.erb +++ /dev/null @@ -1,107 +0,0 @@ -
-

- <%= t('sponsors.sponsorships') %> -

-
- <%= t('sponsors.uni_hd') %> -
- -
- <%= t('sponsors.hse') %> -
- -
\ No newline at end of file diff --git a/app/views/shared/_footer.html.erb b/app/views/shared/_footer.html.erb index c0666d56f..ed42a2b91 100644 --- a/app/views/shared/_footer.html.erb +++ b/app/views/shared/_footer.html.erb @@ -1,4 +1,17 @@ +<%= javascript_include_tag :footer_modal %> + <% I18n.with_locale(current_user.try(:locale)) do %> + +<%# Sponsors modal %> + + +<%# Footbar %>
@@ -39,9 +52,8 @@ target: :_blank)) %>