diff --git a/app/forms/hyrax/forms/admin/appearance_decorator.rb b/app/forms/hyrax/forms/admin/appearance_decorator.rb index b87333a8f..cc03cb6a0 100644 --- a/app/forms/hyrax/forms/admin/appearance_decorator.rb +++ b/app/forms/hyrax/forms/admin/appearance_decorator.rb @@ -35,23 +35,24 @@ module AppearanceDecorator # @!attribute default_colors # @return [Hash] class_attribute :default_colors, default: { - 'header_and_footer_background_color' => '#3c3c3c', + 'active_tabs_background_color' => '#337ab7', + 'default_button_background_color' => '#ffffff', + 'default_button_border_color' => '#cccccc', + 'default_button_text_color' => '#333333', + 'facet_panel_background_color' => '#f5f5f5', + 'facet_panel_text_color' => '#333333', + 'footer_link_color' => '#ffebcd', + 'footer_link_hover_color' => '#ffffff', 'header_and_footer_text_color' => '#dcdcdc', + 'link_color' => '#2e74b2', + 'link_hover_color' => '#215480', 'navbar_background_color' => '#000000', + 'navbar_link_background_color' => '#375f8c', 'navbar_link_background_hover_color' => '#ffffff', 'navbar_link_text_color' => '#eeeeee', 'navbar_link_text_hover_color' => '#eeeeee', - 'link_color' => '#2e74b2', - 'link_hover_color' => '#215480', - 'footer_link_color' => '#ffebcd', - 'footer_link_hover_color' => '#ffffff', 'primary_button_hover_color' => '#286090', - 'default_button_background_color' => '#ffffff', - 'default_button_border_color' => '#cccccc', - 'default_button_text_color' => '#333333', - # 'active_tabs_background_color' => '#337ab7', - 'facet_panel_background_color' => '#f5f5f5', - 'facet_panel_text_color' => '#333333' + 'header_and_footer_background_color' => '#3c3c3c' } # @!endgroup Class Attributes end diff --git a/spec/forms/hyrax/forms/admin/appearance_decorator_spec.rb b/spec/forms/hyrax/forms/admin/appearance_decorator_spec.rb index 0fb32f2a1..7e479cbe1 100644 --- a/spec/forms/hyrax/forms/admin/appearance_decorator_spec.rb +++ b/spec/forms/hyrax/forms/admin/appearance_decorator_spec.rb @@ -3,6 +3,7 @@ require 'spec_helper' RSpec.describe Hyrax::Forms::Admin::Appearance, type: :decorator do + let(:instance) { described_class.new } describe '.default_fonts' do subject { described_class.default_fonts } @@ -26,8 +27,16 @@ end describe '#banner_image' do - subject { described_class.new.banner_image } + subject { instance.banner_image } it { is_expected.to be_a(Hyrax::AvatarUploader) } end + + described_class.instance_methods.grep(/_color$/).each do |color_method_name| + describe "##{color_method_name}" do + subject { instance.send(color_method_name) } + + it { is_expected.to match(/^#[0-9A-F]{6}/i) } + end + end end