2013-12-09 00:34:51 -05:00
|
|
|
module BroadcastMessagesHelper
|
|
|
|
def broadcast_styling(broadcast_message)
|
2015-05-21 17:49:06 -04:00
|
|
|
styling = ''
|
|
|
|
|
|
|
|
if broadcast_message.color.present?
|
|
|
|
styling << "background-color: #{broadcast_message.color}"
|
|
|
|
styling << '; ' if broadcast_message.font.present?
|
2013-12-09 00:34:51 -05:00
|
|
|
end
|
2015-05-21 17:49:06 -04:00
|
|
|
|
|
|
|
if broadcast_message.font.present?
|
|
|
|
styling << "color: #{broadcast_message.font}"
|
|
|
|
end
|
|
|
|
|
|
|
|
styling
|
2013-12-09 00:34:51 -05:00
|
|
|
end
|
|
|
|
end
|