From 1dda77596926fe08990c8a6f31412a38fbc602b5 Mon Sep 17 00:00:00 2001 From: Jeroen Date: Fri, 10 Oct 2014 13:35:16 +0000 Subject: Good compromise I think. Remove display setting . Set the default (light) schema to = , so that other schemas can still use . --- view/theme/redbasic/php/config.php | 3 --- view/theme/redbasic/php/style.php | 5 ++--- view/theme/redbasic/schema/dark.php | 4 ++-- view/theme/redbasic/tpl/theme_settings.tpl | 3 +-- 4 files changed, 5 insertions(+), 10 deletions(-) (limited to 'view/theme') diff --git a/view/theme/redbasic/php/config.php b/view/theme/redbasic/php/config.php index 4c889008a..bfef8216c 100644 --- a/view/theme/redbasic/php/config.php +++ b/view/theme/redbasic/php/config.php @@ -25,7 +25,6 @@ function theme_content(&$a) { $arr['comment_indent'] = get_pconfig(local_user(),'redbasic', 'comment_indent' ); $arr['toolicon_colour'] = get_pconfig(local_user(),'redbasic','toolicon_colour'); $arr['toolicon_activecolour'] = get_pconfig(local_user(),'redbasic','toolicon_activecolour'); - $arr['genericcontent_bgcolour'] = get_pconfig(local_user(),'redbasic', 'genericcontent_bgcolour' ); $arr['font_size'] = get_pconfig(local_user(),'redbasic', 'font_size' ); $arr['body_font_size'] = get_pconfig(local_user(),'redbasic', 'body_font_size' ); $arr['font_colour'] = get_pconfig(local_user(),'redbasic', 'font_colour' ); @@ -64,7 +63,6 @@ function theme_post(&$a) { set_pconfig(local_user(), 'redbasic', 'comment_indent', $_POST['redbasic_comment_indent']); set_pconfig(local_user(), 'redbasic', 'toolicon_colour', $_POST['redbasic_toolicon_colour']); set_pconfig(local_user(), 'redbasic', 'toolicon_activecolour', $_POST['redbasic_toolicon_activecolour']); - set_pconfig(local_user(), 'redbasic', 'genericcontent_bgcolour', $_POST['redbasic_genericcontent_bgcolour']); set_pconfig(local_user(), 'redbasic', 'font_size', $_POST['redbasic_font_size']); set_pconfig(local_user(), 'redbasic', 'body_font_size', $_POST['redbasic_body_font_size']); set_pconfig(local_user(), 'redbasic', 'font_colour', $_POST['redbasic_font_colour']); @@ -122,7 +120,6 @@ if(feature_enabled(local_user(),'expert')) '$comment_indent' => array('redbasic_comment_indent', t('Set the indent for comments'), $arr['comment_indent']), '$toolicon_colour' => array('redbasic_toolicon_colour',t('Set the basic color for item icons'),$arr['toolicon_colour']), '$toolicon_activecolour' => array('redbasic_toolicon_activecolour',t('Set the hover color for item icons'),$arr['toolicon_activecolour']), - '$genericcontent_bgcolour' => array('redbasic_genericcontent_bgcolour',t('Set the background color of other content'),$arr['genericcontent_bgcolour']), '$body_font_size' => array('redbasic_body_font_size', t('Set font-size for the entire application'), $arr['body_font_size']), '$font_size' => array('redbasic_font_size', t('Set font-size for posts and comments'), $arr['font_size']), '$font_colour' => array('redbasic_font_colour', t('Set font-color for posts and comments'), $arr['font_colour']), diff --git a/view/theme/redbasic/php/style.php b/view/theme/redbasic/php/style.php index 104d9d51e..045ddc309 100644 --- a/view/theme/redbasic/php/style.php +++ b/view/theme/redbasic/php/style.php @@ -24,7 +24,6 @@ if(! $a->install) { $background_image = get_pconfig($uid, "redbasic", "background_image"); $toolicon_colour = get_pconfig($uid,'redbasic','toolicon_colour'); $toolicon_activecolour = get_pconfig($uid,'redbasic','toolicon_activecolour'); - $genericcontent_bgcolour = get_pconfig($uid, "redbasic", "genericcontent_bgcolour"); $item_colour = get_pconfig($uid, "redbasic", "item_colour"); $comment_item_colour = get_pconfig($uid, "redbasic", "comment_item_colour"); $comment_border_colour = get_pconfig($uid, "redbasic", "comment_border_colour"); @@ -122,12 +121,12 @@ if(! $a->install) { $bgcolour = "#fdfdfd"; if (! $background_image) $background_image =''; - if (! $genericcontent_bgcolour) - $genericcontent_bgcolour ='rgba(247,247,247,0.8)'; if (! $item_colour) $item_colour = "rgba(238,238,238,0.8)"; if (! $comment_item_colour) $comment_item_colour = "rgba(254,254,254,0.4)"; + if (! $genericcontent_bgcolour) + $genericcontent_bgcolour = $comment_item_colour; if (! $comment_border_colour) $comment_border_colour = "rgba(238,238,238,0.8)"; if (! $toolicon_colour) diff --git a/view/theme/redbasic/schema/dark.php b/view/theme/redbasic/schema/dark.php index f4222c07b..51a6d23a4 100644 --- a/view/theme/redbasic/schema/dark.php +++ b/view/theme/redbasic/schema/dark.php @@ -50,12 +50,12 @@ $search_background = "#999"; if (! $bgcolour) $bgcolour = "#111"; - if (! $genericcontent_bgcolour) - $genericcontent_bgcolour ='rgba(28,28,28,0.8)'; if (! $item_colour) $item_colour = "rgba(28,28,28,0.8)"; if (! $comment_item_colour) $comment_item_colour = "rgba(18,18,18,0.4)"; + if (! $genericcontent_bgcolour) + $genericcontent_bgcolour = "rgba(28,28,28,0.8)"; if (! $comment_border_colour) $comment_border_colour = "rgba(28,28,28,0.8)"; if (! $toolicon_colour) diff --git a/view/theme/redbasic/tpl/theme_settings.tpl b/view/theme/redbasic/tpl/theme_settings.tpl index 73e0f3476..70b42b6cd 100644 --- a/view/theme/redbasic/tpl/theme_settings.tpl +++ b/view/theme/redbasic/tpl/theme_settings.tpl @@ -24,7 +24,6 @@ {{include file="field_input.tpl" field=$comment_indent}} {{include file="field_colorinput.tpl" field=$toolicon_colour}} {{include file="field_colorinput.tpl" field=$toolicon_activecolour}} -{{include file="field_colorinput.tpl" field=$genericcontent_bgcolour}} {{include file="field_input.tpl" field=$body_font_size}} {{include file="field_input.tpl" field=$font_size}} {{include file="field_colorinput.tpl" field=$font_colour}} @@ -41,7 +40,7 @@ $('#id_redbasic_nav_bg,#id_redbasic_nav_gradient_top,#id_redbasic_nav_gradient_bottom,#id_redbasic_nav_active_gradient_top,#id_redbasic_nav_active_gradient_bottom').colorpicker(); $('#id_redbasic_nav_bd,#id_redbasic_nav_icon_colour ,#id_redbasic_nav_active_icon_colour,#id_redbasic_banner_colour,#id_redbasic_link_colour,#id_redbasic_background_colour').colorpicker(); $('#id_redbasic_toolicon_colour,#id_redbasic_toolicon_activecolour,#id_redbasic_font_colour').colorpicker(); - $('#id_redbasic_item_colour,#id_redbasic_comment_item_colour,#id_redbasic_comment_border_colour,#id_redbasic_genericcontent_bgcolour').colorpicker({format: 'rgba'}); + $('#id_redbasic_item_colour,#id_redbasic_comment_item_colour,#id_redbasic_comment_border_colour').colorpicker({format: 'rgba'}); }); -- cgit v1.2.3 From 4e9bd8b8f0a2629cf1ad7c7274369e795852a8ab Mon Sep 17 00:00:00 2001 From: marijus Date: Fri, 10 Oct 2014 15:52:56 +0200 Subject: This is a fix to not interfere the ongoing adding of .generic-content-wrapper with the ongoing styling of redbasic theme. adding of .generic-content-wrapper is needed and useful for derivative themes but it should not contain any styling information for redbasic theme. therefor i added .generic-content-wrapper-styled as a quickfix for spots where redbasic is not finished yet. Sidenote: please avoid opening a div in one *.tpl and close it in another or (even worse) open a div in a *.tpl and close it in an already templatified mod/*.php. This will really make the code and templates very, very confusing. --- view/theme/redbasic/css/style.css | 2 +- view/theme/redbasic/php/style.php | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) (limited to 'view/theme') diff --git a/view/theme/redbasic/css/style.css b/view/theme/redbasic/css/style.css index 57e24e746..c448c877f 100644 --- a/view/theme/redbasic/css/style.css +++ b/view/theme/redbasic/css/style.css @@ -1868,7 +1868,7 @@ img.mail-list-sender-photo { border-top-left-radius: $radiuspx; } -.generic-content-wrapper { +.generic-content-wrapper-styled { background-color: $genericcontent_bgcolour; padding: 10px; border-radius: $radiuspx; diff --git a/view/theme/redbasic/php/style.php b/view/theme/redbasic/php/style.php index 045ddc309..495095fe2 100644 --- a/view/theme/redbasic/php/style.php +++ b/view/theme/redbasic/php/style.php @@ -24,6 +24,7 @@ if(! $a->install) { $background_image = get_pconfig($uid, "redbasic", "background_image"); $toolicon_colour = get_pconfig($uid,'redbasic','toolicon_colour'); $toolicon_activecolour = get_pconfig($uid,'redbasic','toolicon_activecolour'); + $genericcontent_bgcolour = get_pconfig($uid, "redbasic", "genericcontent_bgcolour"); $item_colour = get_pconfig($uid, "redbasic", "item_colour"); $comment_item_colour = get_pconfig($uid, "redbasic", "comment_item_colour"); $comment_border_colour = get_pconfig($uid, "redbasic", "comment_border_colour"); @@ -121,12 +122,12 @@ if(! $a->install) { $bgcolour = "#fdfdfd"; if (! $background_image) $background_image =''; + if (! $genericcontent_bgcolour) + $genericcontent_bgcolour ='rgba(254,254,254,0.8)'; if (! $item_colour) $item_colour = "rgba(238,238,238,0.8)"; if (! $comment_item_colour) $comment_item_colour = "rgba(254,254,254,0.4)"; - if (! $genericcontent_bgcolour) - $genericcontent_bgcolour = $comment_item_colour; if (! $comment_border_colour) $comment_border_colour = "rgba(238,238,238,0.8)"; if (! $toolicon_colour) -- cgit v1.2.3 From 675f5cadede3c3b0dd5fc1da7d11db4b8fd0c958 Mon Sep 17 00:00:00 2001 From: marijus Date: Fri, 10 Oct 2014 15:57:10 +0200 Subject: oups... that was weired... --- view/theme/redbasic/php/style.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'view/theme') diff --git a/view/theme/redbasic/php/style.php b/view/theme/redbasic/php/style.php index 495095fe2..b16c6adeb 100644 --- a/view/theme/redbasic/php/style.php +++ b/view/theme/redbasic/php/style.php @@ -24,7 +24,6 @@ if(! $a->install) { $background_image = get_pconfig($uid, "redbasic", "background_image"); $toolicon_colour = get_pconfig($uid,'redbasic','toolicon_colour'); $toolicon_activecolour = get_pconfig($uid,'redbasic','toolicon_activecolour'); - $genericcontent_bgcolour = get_pconfig($uid, "redbasic", "genericcontent_bgcolour"); $item_colour = get_pconfig($uid, "redbasic", "item_colour"); $comment_item_colour = get_pconfig($uid, "redbasic", "comment_item_colour"); $comment_border_colour = get_pconfig($uid, "redbasic", "comment_border_colour"); @@ -123,7 +122,7 @@ if(! $a->install) { if (! $background_image) $background_image =''; if (! $genericcontent_bgcolour) - $genericcontent_bgcolour ='rgba(254,254,254,0.8)'; + $genericcontent_bgcolour = $comment_item_colour; if (! $item_colour) $item_colour = "rgba(238,238,238,0.8)"; if (! $comment_item_colour) -- cgit v1.2.3 From 92cc5673ccb9589361d0386876ef6df510188c0c Mon Sep 17 00:00:00 2001 From: marijus Date: Fri, 10 Oct 2014 16:01:14 +0200 Subject: one more oups... --- view/theme/redbasic/php/style.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'view/theme') diff --git a/view/theme/redbasic/php/style.php b/view/theme/redbasic/php/style.php index b16c6adeb..045ddc309 100644 --- a/view/theme/redbasic/php/style.php +++ b/view/theme/redbasic/php/style.php @@ -121,12 +121,12 @@ if(! $a->install) { $bgcolour = "#fdfdfd"; if (! $background_image) $background_image =''; - if (! $genericcontent_bgcolour) - $genericcontent_bgcolour = $comment_item_colour; if (! $item_colour) $item_colour = "rgba(238,238,238,0.8)"; if (! $comment_item_colour) $comment_item_colour = "rgba(254,254,254,0.4)"; + if (! $genericcontent_bgcolour) + $genericcontent_bgcolour = $comment_item_colour; if (! $comment_border_colour) $comment_border_colour = "rgba(238,238,238,0.8)"; if (! $toolicon_colour) -- cgit v1.2.3