add ability for custom branding images

This commit is contained in:
Joshua Arts 2018-07-11 15:33:35 -04:00
parent 20a2c570ba
commit f5ab362f96
3 changed files with 10 additions and 8 deletions

View File

@ -1,14 +1,9 @@
<div class="header py-4">
<div class="container">
<div class="d-flex">
<% if current_user %>
<%= link_to current_user.main_room, class: "header-brand" do %>
<%= image_tag("logo_with_text.png", class: "header-brand-img") %>
<% end %>
<% else %>
<%= link_to root_path, class: "header-brand" do %>
<%= image_tag("logo_with_text.png", class: "header-brand-img") %>
<% end %>
<%= link_to (current_user ? current_user.main_room : root_path), class: "header-brand" do %>
<%= image_tag(Rails.configuration.branding_image.blank? ? "logo_with_text.png" : Rails.configuration.branding_image,
class: "header-brand-img") %>
<% end %>
<div class="d-flex ml-auto">

View File

@ -50,5 +50,8 @@ module Greenlight
# Configure custom banner message.
config.banner_message = ENV['BANNER_MESSAGE']
# Configure custom branding image.
config.branding_image = ENV['BRANDING_IMAGE']
end
end

View File

@ -53,3 +53,7 @@ ALLOW_GREENLIGHT_ACCOUNTS=true
# The recommended prefix is "/b".
#
RELATIVE_URL_ROOT=/b
# A URL to the image you want to appear in the top right corner of Greenlight.
# By default, this is the BigBlueButton logo.
BRANDING_IMAGE=