added themes deprecated or deleted at Hackathon 2016 in Berlin as they were at the 3.5 release
This commit is contained in:
parent
c39a9c812b
commit
aa199e931f
1344 changed files with 164625 additions and 0 deletions
127
cleanzero/cleanzero-green/style.css
Normal file
127
cleanzero/cleanzero-green/style.css
Normal file
|
@ -0,0 +1,127 @@
|
|||
@import url('../greenzero/style.css');
|
||||
body {background-image:none;
|
||||
|
||||
}
|
||||
|
||||
.wall-item-content-wrapper {
|
||||
border-top: 1px solid #ccc;
|
||||
//border-top:none;
|
||||
border-left:none;
|
||||
border-right:none;
|
||||
border-radius:0px;
|
||||
//border:none;
|
||||
//background: #f8f8f8 !important;
|
||||
}
|
||||
|
||||
.wall-item-content-wrapper.comment {
|
||||
// background: #f8f8f8 !important;
|
||||
// border-left: 1px solid #ccc;
|
||||
border-top: 1px solid #ccc;
|
||||
border-left:none;
|
||||
border-right:none;
|
||||
border-radius:0px;
|
||||
}
|
||||
|
||||
.wall-item-tools {
|
||||
// border-top: 1px solid #ccc;
|
||||
// background: #f8f8f8 !important;
|
||||
background: #ffffff !important;
|
||||
}
|
||||
|
||||
.comment-edit-text-empty, .comment-edit-text-full {
|
||||
border: 1px solid #ccc;
|
||||
border-left: 1px solid #EEE;
|
||||
background: #ffffff;
|
||||
}
|
||||
|
||||
.comment-edit-wrapper, .comment-wwedit-wrapper {
|
||||
// background: #ffffff; !important;
|
||||
//background: #f8f8f8 !important;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
section {
|
||||
margin: 0px 10%;
|
||||
margin-right:12%;
|
||||
background-image:none;
|
||||
}
|
||||
|
||||
aside {
|
||||
margin-left: 10%;
|
||||
background-image:none;
|
||||
}
|
||||
nav {
|
||||
margin-left: 32px;
|
||||
margin-right: 5%;
|
||||
|
||||
}
|
||||
|
||||
nav #site-location {
|
||||
top: 80px;
|
||||
right: 5%;
|
||||
|
||||
}
|
||||
|
||||
.wall-item-photo, .photo, .contact-block-img, .my-comment-photo {
|
||||
border-radius: 3px;
|
||||
-moz-border-radius: 3px;
|
||||
}
|
||||
|
||||
.tabs { background-image:none;
|
||||
|
||||
}
|
||||
.tab.active {
|
||||
padding: 3px;
|
||||
-moz-border-radius: 3px;
|
||||
border-radius: 3px;
|
||||
border: 1px solid #CCCCCC;
|
||||
//background: #F8F8F8;
|
||||
font-weight: bold;
|
||||
}
|
||||
.tab { margin-right: 1px ;
|
||||
|
||||
}
|
||||
|
||||
#group-sidebar {
|
||||
margin-bottom: 10px;
|
||||
border:none;
|
||||
}
|
||||
|
||||
#nets-sidebar {
|
||||
margin-bottom: 10px;
|
||||
border:none;
|
||||
}
|
||||
|
||||
#saved-search-list {
|
||||
border:none;
|
||||
}
|
||||
blockquote {
|
||||
//background-color: #f8f8f8;
|
||||
border: 1px solid #ccc;
|
||||
-moz-border-radius: 3px;
|
||||
|
||||
border-radius: 3px;
|
||||
}
|
||||
.widget {
|
||||
border: none;
|
||||
}
|
||||
|
||||
|
||||
.wall-item-content {
|
||||
max-height: 20000px;
|
||||
overflow: none;
|
||||
}
|
||||
|
||||
.nav-commlink, .nav-login-link {
|
||||
margin-top: 67px;
|
||||
height: 15px;
|
||||
float:left;
|
||||
padding: 6px 3px;
|
||||
}
|
||||
|
||||
nav .nav-link {
|
||||
//float: left;
|
||||
}
|
127
cleanzero/cleanzero-purple/style.css
Normal file
127
cleanzero/cleanzero-purple/style.css
Normal file
|
@ -0,0 +1,127 @@
|
|||
@import url('../purplezero/style.css');
|
||||
body {background-image:none;
|
||||
|
||||
}
|
||||
|
||||
.wall-item-content-wrapper {
|
||||
border-top: 1px solid #ccc;
|
||||
//border-top:none;
|
||||
border-left:none;
|
||||
border-right:none;
|
||||
border-radius:0px;
|
||||
//border:none;
|
||||
//background: #f8f8f8 !important;
|
||||
}
|
||||
|
||||
.wall-item-content-wrapper.comment {
|
||||
// background: #f8f8f8 !important;
|
||||
// border-left: 1px solid #ccc;
|
||||
border-top: 1px solid #ccc;
|
||||
border-left:none;
|
||||
border-right:none;
|
||||
border-radius:0px;
|
||||
}
|
||||
|
||||
.wall-item-tools {
|
||||
// border-top: 1px solid #ccc;
|
||||
// background: #f8f8f8 !important;
|
||||
background: #ffffff !important;
|
||||
}
|
||||
|
||||
.comment-edit-text-empty, .comment-edit-text-full {
|
||||
border: 1px solid #ccc;
|
||||
border-left: 1px solid #EEE;
|
||||
background: #ffffff;
|
||||
}
|
||||
|
||||
.comment-edit-wrapper, .comment-wwedit-wrapper {
|
||||
// background: #ffffff; !important;
|
||||
// background: #f8f8f8 !important;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
section {
|
||||
margin: 0px 10%;
|
||||
margin-right:12%;
|
||||
background-image:none;
|
||||
}
|
||||
|
||||
aside {
|
||||
margin-left: 10%;
|
||||
background-image:none;
|
||||
}
|
||||
nav {
|
||||
margin-left: 32px;
|
||||
margin-right: 5%;
|
||||
|
||||
}
|
||||
|
||||
nav #site-location {
|
||||
top: 80px;
|
||||
right: 5%;
|
||||
|
||||
}
|
||||
|
||||
.wall-item-photo, .photo, .contact-block-img, .my-comment-photo {
|
||||
border-radius: 3px;
|
||||
-moz-border-radius: 3px;
|
||||
}
|
||||
|
||||
.tabs { background-image:none;
|
||||
|
||||
}
|
||||
.tab.active {
|
||||
padding: 3px;
|
||||
-moz-border-radius: 3px;
|
||||
border-radius: 3px;
|
||||
border: 1px solid #CCCCCC;
|
||||
// background: #F8F8F8;
|
||||
font-weight: bold;
|
||||
}
|
||||
.tab { margin-right: 1px ;
|
||||
|
||||
}
|
||||
|
||||
#group-sidebar {
|
||||
margin-bottom: 10px;
|
||||
border:none;
|
||||
}
|
||||
|
||||
#nets-sidebar {
|
||||
margin-bottom: 10px;
|
||||
border:none;
|
||||
}
|
||||
|
||||
#saved-search-list {
|
||||
border:none;
|
||||
}
|
||||
blockquote {
|
||||
background-color: #f8f8f8;
|
||||
border: 1px solid #ccc;
|
||||
-moz-border-radius: 3px;
|
||||
|
||||
border-radius: 3px;
|
||||
}
|
||||
.widget {
|
||||
border: none;
|
||||
}
|
||||
|
||||
|
||||
.wall-item-content {
|
||||
max-height: 20000px;
|
||||
overflow: none;
|
||||
}
|
||||
|
||||
.nav-commlink, .nav-login-link {
|
||||
margin-top: 67px;
|
||||
height: 15px;
|
||||
float:left;
|
||||
padding: 6px 3px;
|
||||
}
|
||||
|
||||
nav .nav-link {
|
||||
//float: left;
|
||||
}
|
127
cleanzero/cleanzero/style.css
Normal file
127
cleanzero/cleanzero/style.css
Normal file
|
@ -0,0 +1,127 @@
|
|||
@import url('../duepuntozero/style.css');
|
||||
body {background-image:none;
|
||||
|
||||
}
|
||||
|
||||
.wall-item-content-wrapper {
|
||||
border-top: 1px solid #ccc;
|
||||
//border-top:none;
|
||||
border-left:none;
|
||||
border-right:none;
|
||||
border-radius:0px;
|
||||
//border:none;
|
||||
//background: #f8f8f8 !important;
|
||||
}
|
||||
|
||||
.wall-item-content-wrapper.comment {
|
||||
background: #f8f8f8 !important;
|
||||
// border-left: 1px solid #ccc;
|
||||
border-top: 1px solid #ccc;
|
||||
border-left:none;
|
||||
border-right:none;
|
||||
border-radius:0px;
|
||||
}
|
||||
|
||||
.wall-item-tools {
|
||||
// border-top: 1px solid #ccc;
|
||||
// background: #f8f8f8 !important;
|
||||
background: #ffffff !important;
|
||||
}
|
||||
|
||||
.comment-edit-text-empty, .comment-edit-text-full {
|
||||
border: 1px solid #ccc;
|
||||
border-left: 1px solid #EEE;
|
||||
background: #ffffff;
|
||||
}
|
||||
|
||||
.comment-edit-wrapper, .comment-wwedit-wrapper {
|
||||
// background: #ffffff; !important;
|
||||
background: #f8f8f8 !important;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
section {
|
||||
margin: 0px 10%;
|
||||
margin-right:12%;
|
||||
background-image:none;
|
||||
}
|
||||
|
||||
aside {
|
||||
margin-left: 10%;
|
||||
background-image:none;
|
||||
}
|
||||
nav {
|
||||
margin-left: 32px;
|
||||
margin-right: 5%;
|
||||
|
||||
}
|
||||
|
||||
nav #site-location {
|
||||
top: 80px;
|
||||
right: 5%;
|
||||
|
||||
}
|
||||
|
||||
.wall-item-photo, .photo, .contact-block-img, .my-comment-photo {
|
||||
border-radius: 3px;
|
||||
-moz-border-radius: 3px;
|
||||
}
|
||||
|
||||
.tabs { background-image:none;
|
||||
|
||||
}
|
||||
.tab.active {
|
||||
padding: 3px;
|
||||
-moz-border-radius: 3px;
|
||||
border-radius: 3px;
|
||||
border: 1px solid #CCCCCC;
|
||||
background: #F8F8F8;
|
||||
font-weight: bold;
|
||||
}
|
||||
.tab { margin-right: 1px ;
|
||||
|
||||
}
|
||||
|
||||
#group-sidebar {
|
||||
margin-bottom: 10px;
|
||||
border:none;
|
||||
}
|
||||
|
||||
#nets-sidebar {
|
||||
margin-bottom: 10px;
|
||||
border:none;
|
||||
}
|
||||
|
||||
#saved-search-list {
|
||||
border:none;
|
||||
}
|
||||
blockquote {
|
||||
background-color: #f8f8f8;
|
||||
border: 1px solid #ccc;
|
||||
-moz-border-radius: 3px;
|
||||
|
||||
border-radius: 3px;
|
||||
}
|
||||
.widget {
|
||||
border: none;
|
||||
}
|
||||
|
||||
|
||||
.wall-item-content {
|
||||
max-height: 20000px;
|
||||
overflow: none;
|
||||
}
|
||||
|
||||
.nav-commlink, .nav-login-link {
|
||||
margin-top: 67px;
|
||||
height: 15px;
|
||||
float:left;
|
||||
padding: 6px 3px;
|
||||
}
|
||||
|
||||
nav .nav-link {
|
||||
//float: left;
|
||||
}
|
89
cleanzero/config.php
Normal file
89
cleanzero/config.php
Normal file
|
@ -0,0 +1,89 @@
|
|||
<?php
|
||||
/**
|
||||
* Theme settings
|
||||
*/
|
||||
|
||||
|
||||
|
||||
function theme_content(&$a){
|
||||
if(!local_user())
|
||||
return;
|
||||
|
||||
$resize = get_pconfig(local_user(), 'cleanzero', 'resize' );
|
||||
$color = get_pconfig(local_user(), 'cleanzero', 'color' );
|
||||
$font_size = get_pconfig(local_user(), 'cleanzero', 'font_size' );
|
||||
$theme_width= get_pconfig(local_user(), 'cleanzero', 'theme_width' );
|
||||
|
||||
return cleanzero_form($a,$color,$font_size,$resize,$theme_width);
|
||||
}
|
||||
|
||||
function theme_post(&$a){
|
||||
if(! local_user())
|
||||
return;
|
||||
|
||||
if (isset($_POST['cleanzero-settings-submit'])){
|
||||
set_pconfig(local_user(), 'cleanzero', 'resize', $_POST['cleanzero_resize']);
|
||||
set_pconfig(local_user(), 'cleanzero', 'color', $_POST['cleanzero_color']);
|
||||
set_pconfig(local_user(), 'cleanzero', 'font_size', $_POST['cleanzero_font_size']);
|
||||
set_pconfig(local_user(), 'cleanzero', 'theme_width', $_POST['cleanzero_theme_width']);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
function theme_admin(&$a){
|
||||
$resize = get_config('cleanzero', 'resize' );
|
||||
$color = get_config('cleanzero', 'color' );
|
||||
$font_size = get_config('cleanzero', 'font_size' );
|
||||
$theme_width= get_config('cleanzero', 'theme_width' );
|
||||
return cleanzero_form($a,$color,$font_size,$resize,$theme_width);
|
||||
}
|
||||
|
||||
function theme_admin_post(&$a){
|
||||
if (isset($_POST['cleanzero-settings-submit'])){
|
||||
set_config('cleanzero', 'resize', $_POST['cleanzero_resize']);
|
||||
set_config('cleanzero', 'color', $_POST['cleanzero_color']);
|
||||
set_config('cleanzero', 'font_size', $_POST['cleanzero_font_size']);
|
||||
set_config('cleanzero', 'theme_width', $_POST['cleanzero_theme_width']);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
function cleanzero_form(&$a, $color,$font_size,$resize,$theme_width){
|
||||
$colors = array(
|
||||
"cleanzero"=>"cleanzero",
|
||||
"cleanzero-green"=>"green",
|
||||
"cleanzero-purple"=>"purple"
|
||||
);
|
||||
$font_sizes = array(
|
||||
'12'=>'12',
|
||||
"---"=>"---",
|
||||
"16"=>"16",
|
||||
"14"=>"14",
|
||||
'10'=>'10',
|
||||
);
|
||||
$resizes = array(
|
||||
"0"=>"0 (no resizing)",
|
||||
"600"=>"1 (600px)",
|
||||
"300"=>"2 (300px)",
|
||||
"250"=>"3 (250px)",
|
||||
"150"=>"4 (150px)",
|
||||
);
|
||||
$theme_widths =array (
|
||||
"standard"=>"standard",
|
||||
"narrow"=>"narrow",
|
||||
"wide"=>"wide",
|
||||
);
|
||||
|
||||
$t = get_markup_template("theme_settings.tpl" );
|
||||
$o .= replace_macros($t, array(
|
||||
'$submit' => t('Submit'),
|
||||
'$baseurl' => $a->get_baseurl(),
|
||||
'$title' => t("Theme settings"),
|
||||
'$resize' => array('cleanzero_resize',t ('Set resize level for images in posts and comments (width and height)'),$resize,'',$resizes),
|
||||
'$font_size' => array('cleanzero_font_size', t('Set font-size for posts and comments'), $font_size, '', $font_sizes),
|
||||
'$theme_width' => array('cleanzero_theme_width', t('Set theme width'), $theme_width, '', $theme_widths),
|
||||
'$color' => array('cleanzero_color', t('Color scheme'), $color, '', $colors),
|
||||
));
|
||||
return $o;
|
||||
}
|
69
cleanzero/js/jquery.ae.image.resize.js
Normal file
69
cleanzero/js/jquery.ae.image.resize.js
Normal file
|
@ -0,0 +1,69 @@
|
|||
(function( $ ) {
|
||||
|
||||
$.fn.aeImageResize = function( params ) {
|
||||
|
||||
var aspectRatio = 0
|
||||
// Nasty I know but it's done only once, so not too bad I guess
|
||||
// Alternate suggestions welcome :)
|
||||
, isIE6 = $.browser.msie && (6 == ~~ $.browser.version)
|
||||
;
|
||||
|
||||
// We cannot do much unless we have one of these
|
||||
if ( !params.height && !params.width ) {
|
||||
return this;
|
||||
}
|
||||
|
||||
// Calculate aspect ratio now, if possible
|
||||
if ( params.height && params.width ) {
|
||||
aspectRatio = params.width / params.height;
|
||||
}
|
||||
|
||||
// Attach handler to load
|
||||
// Handler is executed just once per element
|
||||
// Load event required for Webkit browsers
|
||||
return this.one( "load", function() {
|
||||
|
||||
// Remove all attributes and CSS rules
|
||||
this.removeAttribute( "height" );
|
||||
this.removeAttribute( "width" );
|
||||
this.style.height = this.style.width = "";
|
||||
|
||||
var imgHeight = this.height
|
||||
, imgWidth = this.width
|
||||
, imgAspectRatio = imgWidth / imgHeight
|
||||
, bxHeight = params.height
|
||||
, bxWidth = params.width
|
||||
, bxAspectRatio = aspectRatio;
|
||||
|
||||
// Work the magic!
|
||||
// If one parameter is missing, we just force calculate it
|
||||
if ( !bxAspectRatio ) {
|
||||
if ( bxHeight ) {
|
||||
bxAspectRatio = imgAspectRatio + 1;
|
||||
} else {
|
||||
bxAspectRatio = imgAspectRatio - 1;
|
||||
}
|
||||
}
|
||||
|
||||
// Only resize the images that need resizing
|
||||
if ( (bxHeight && imgHeight > bxHeight) || (bxWidth && imgWidth > bxWidth) ) {
|
||||
|
||||
if ( imgAspectRatio > bxAspectRatio ) {
|
||||
bxHeight = ~~ ( imgHeight / imgWidth * bxWidth );
|
||||
} else {
|
||||
bxWidth = ~~ ( imgWidth / imgHeight * bxHeight );
|
||||
}
|
||||
|
||||
this.height = bxHeight;
|
||||
this.width = bxWidth;
|
||||
}
|
||||
})
|
||||
.each(function() {
|
||||
|
||||
// Trigger load event (for Gecko and MSIE)
|
||||
if ( this.complete || isIE6 ) {
|
||||
$( this ).trigger( "load" );
|
||||
}
|
||||
});
|
||||
};
|
||||
})( jQuery );
|
1
cleanzero/js/jquery.ae.image.resize.min.js
vendored
Normal file
1
cleanzero/js/jquery.ae.image.resize.min.js
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
(function(d){d.fn.aeImageResize=function(a){var i=0,j=d.browser.msie&&6==~~d.browser.version;if(!a.height&&!a.width)return this;if(a.height&&a.width)i=a.width/a.height;return this.one("load",function(){this.removeAttribute("height");this.removeAttribute("width");this.style.height=this.style.width="";var e=this.height,f=this.width,g=f/e,b=a.height,c=a.width,h=i;h||(h=b?g+1:g-1);if(b&&e>b||c&&f>c){if(g>h)b=~~(e/f*c);else c=~~(f/e*b);this.height=b;this.width=c}}).each(function(){if(this.complete||j)d(this).trigger("load")})}})(jQuery);
|
BIN
cleanzero/screenshot.png
Normal file
BIN
cleanzero/screenshot.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 123 KiB |
127
cleanzero/style.css
Normal file
127
cleanzero/style.css
Normal file
|
@ -0,0 +1,127 @@
|
|||
@import url('../duepuntozero/style.css');
|
||||
body {background-image:none;
|
||||
|
||||
}
|
||||
|
||||
.wall-item-content-wrapper {
|
||||
border-top: 1px solid #ccc;
|
||||
//border-top:none;
|
||||
border-left:none;
|
||||
border-right:none;
|
||||
border-radius:0px;
|
||||
//border:none;
|
||||
//background: #f8f8f8 !important;
|
||||
}
|
||||
|
||||
.wall-item-content-wrapper.comment {
|
||||
background: #f8f8f8 !important;
|
||||
// border-left: 1px solid #ccc;
|
||||
border-top: 1px solid #ccc;
|
||||
border-left:none;
|
||||
border-right:none;
|
||||
border-radius:0px;
|
||||
}
|
||||
|
||||
.wall-item-tools {
|
||||
// border-top: 1px solid #ccc;
|
||||
// background: #f8f8f8 !important;
|
||||
background: #ffffff !important;
|
||||
}
|
||||
|
||||
.comment-edit-text-empty, .comment-edit-text-full {
|
||||
border: 1px solid #ccc;
|
||||
border-left: 1px solid #EEE;
|
||||
background: #ffffff;
|
||||
}
|
||||
|
||||
.comment-edit-wrapper, .comment-wwedit-wrapper {
|
||||
// background: #ffffff; !important;
|
||||
background: #f8f8f8 !important;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
section {
|
||||
margin: 0px 10%;
|
||||
margin-right:12%;
|
||||
background-image:none;
|
||||
}
|
||||
|
||||
aside {
|
||||
margin-left: 10%;
|
||||
background-image:none;
|
||||
}
|
||||
nav {
|
||||
margin-left: 32px;
|
||||
margin-right: 5%;
|
||||
|
||||
}
|
||||
|
||||
nav #site-location {
|
||||
top: 80px;
|
||||
right: 5%;
|
||||
|
||||
}
|
||||
|
||||
.wall-item-photo, .photo, .contact-block-img, .my-comment-photo {
|
||||
border-radius: 3px;
|
||||
-moz-border-radius: 3px;
|
||||
}
|
||||
|
||||
.tabs { background-image:none;
|
||||
|
||||
}
|
||||
.tab.active {
|
||||
padding: 3px;
|
||||
-moz-border-radius: 3px;
|
||||
border-radius: 3px;
|
||||
border: 1px solid #CCCCCC;
|
||||
background: #F8F8F8;
|
||||
font-weight: bold;
|
||||
}
|
||||
.tab { margin-right: 1px ;
|
||||
|
||||
}
|
||||
|
||||
#group-sidebar {
|
||||
margin-bottom: 10px;
|
||||
border:none;
|
||||
}
|
||||
|
||||
#nets-sidebar {
|
||||
margin-bottom: 10px;
|
||||
border:none;
|
||||
}
|
||||
|
||||
#saved-search-list {
|
||||
border:none;
|
||||
}
|
||||
blockquote {
|
||||
background-color: #f8f8f8;
|
||||
border: 1px solid #ccc;
|
||||
-moz-border-radius: 3px;
|
||||
|
||||
border-radius: 3px;
|
||||
}
|
||||
.widget {
|
||||
border: none;
|
||||
}
|
||||
|
||||
|
||||
.wall-item-content {
|
||||
max-height: 20000px;
|
||||
overflow: none;
|
||||
}
|
||||
|
||||
.nav-commlink, .nav-login-link {
|
||||
margin-top: 67px;
|
||||
height: 15px;
|
||||
float:left;
|
||||
padding: 6px 3px;
|
||||
}
|
||||
|
||||
nav .nav-link {
|
||||
//float: left;
|
||||
}
|
140
cleanzero/style.php
Normal file
140
cleanzero/style.php
Normal file
|
@ -0,0 +1,140 @@
|
|||
<?php
|
||||
$color=false;
|
||||
$cleanzero_font_size=false;
|
||||
$cleanzero_theme_width=false;
|
||||
|
||||
$site_color = get_config("cleanzero","color");
|
||||
$site_cleanzero_font_size = get_config("cleanzero", "font_size" );
|
||||
$site_cleanzero_theme_width = get_config("cleanzero", "theme_width");
|
||||
|
||||
if (local_user()) {
|
||||
$color = get_pconfig(local_user(), "cleanzero","color");
|
||||
$cleanzero_font_size = get_pconfig(local_user(), "cleanzero", "font_size");
|
||||
$cleanzero_theme_width = get_pconfig(local_user(), "cleanzero", "theme_width");
|
||||
|
||||
}
|
||||
|
||||
if ($color===false) $color=$site_color;
|
||||
if ($color===false) $color="cleanzero";
|
||||
if ($cleanzero_font_size===false) $cleanzero_font_size=$site_cleanzero_font_size;
|
||||
if ($cleanzero_theme_width===false) $cleanzero_theme_width=$site_cleanzero_theme_width;
|
||||
if ($cleanzero_theme_width===false) $cleanzero_theme_width="standard";
|
||||
|
||||
|
||||
if (file_exists("$THEMEPATH/$color/style.css")){
|
||||
echo file_get_contents("$THEMEPATH/$color/style.css");
|
||||
}
|
||||
|
||||
|
||||
|
||||
if($cleanzero_font_size == "16"){
|
||||
echo "
|
||||
.wall-item-content-wrapper {
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.wall-item-content-wrapper.comment {
|
||||
font-size: 16px;
|
||||
}
|
||||
";
|
||||
}
|
||||
if($cleanzero_font_size == "14"){
|
||||
echo "
|
||||
.wall-item-content-wrapper {
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.wall-item-content-wrapper.comment {
|
||||
font-size: 14px;
|
||||
}
|
||||
";
|
||||
}
|
||||
if($cleanzero_font_size == "12"){
|
||||
echo "
|
||||
.wall-item-content-wrapper {
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
.wall-item-content-wrapper.comment {
|
||||
font-size: 12px;
|
||||
}
|
||||
";
|
||||
}
|
||||
if($cleanzero_font_size == "10"){
|
||||
echo "
|
||||
.wall-item-content-wrapper {
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
.wall-item-content-wrapper.comment {
|
||||
font-size: 10px;
|
||||
}
|
||||
";
|
||||
}
|
||||
if ($cleanzero_theme_width === "standard") {
|
||||
echo "
|
||||
section {
|
||||
margin: 0px 10%;
|
||||
margin-right:10%;
|
||||
}
|
||||
|
||||
aside {
|
||||
margin-left: 10%;
|
||||
}
|
||||
nav {
|
||||
margin-left: 10%;
|
||||
margin-right: 10%;
|
||||
|
||||
}
|
||||
|
||||
nav #site-location {
|
||||
right: 10%;
|
||||
|
||||
}
|
||||
";
|
||||
}
|
||||
|
||||
if ($cleanzero_theme_width === "narrow") {
|
||||
echo "
|
||||
section {
|
||||
margin: 0px 15%;
|
||||
margin-right:15%;
|
||||
}
|
||||
|
||||
aside {
|
||||
margin-left: 15%;
|
||||
}
|
||||
nav {
|
||||
margin-left: 15%;
|
||||
margin-right: 15%;
|
||||
|
||||
}
|
||||
|
||||
nav #site-location {
|
||||
right: 15%;
|
||||
|
||||
}
|
||||
";
|
||||
}
|
||||
if ($cleanzero_theme_width === "wide") {
|
||||
echo "
|
||||
section {
|
||||
margin: 0px 5%;
|
||||
margin-right:5%;
|
||||
}
|
||||
|
||||
aside {
|
||||
margin-left: 5%;
|
||||
}
|
||||
nav {
|
||||
margin-left: 5%;
|
||||
margin-right: 5%;
|
||||
|
||||
}
|
||||
|
||||
nav #site-location {
|
||||
right: 5%;
|
||||
|
||||
}
|
||||
";
|
||||
}
|
86
cleanzero/templates/nav.tpl
Normal file
86
cleanzero/templates/nav.tpl
Normal file
|
@ -0,0 +1,86 @@
|
|||
|
||||
<nav>
|
||||
{{$langselector}}
|
||||
|
||||
<div id="site-location">{{$sitelocation}}</div>
|
||||
|
||||
|
||||
<span id="nav-commlink-wrapper">
|
||||
|
||||
{{if $nav.register}}<a id="nav-register-link" class="nav-commlink {{$nav.register.2}} {{$sel.register}}" href="{{$nav.register.0}}" title="{{$nav.register.3}}" >{{$nav.register.1}}</a>{{/if}}
|
||||
|
||||
|
||||
|
||||
{{if $nav.network}}
|
||||
<a id="nav-network-link" class="nav-commlink {{$nav.network.2}} {{$sel.network}}" href="{{$nav.network.0}}" title="{{$nav.network.3}}" >{{$nav.network.1}}</a>
|
||||
<span id="net-update" class="nav-ajax-left"></span>
|
||||
{{/if}}
|
||||
{{if $nav.home}}
|
||||
<a id="nav-home-link" class="nav-commlink {{$nav.home.2}} {{$sel.home}}" href="{{$nav.home.0}}" title="{{$nav.home.3}}" >{{$nav.home.1}}</a>
|
||||
<span id="home-update" class="nav-ajax-left"></span>
|
||||
{{/if}}
|
||||
{{if $nav.community}}
|
||||
<a id="nav-community-link" class="nav-commlink {{$nav.community.2}} {{$sel.community}}" href="{{$nav.community.0}}" title="{{$nav.community.3}}" >{{$nav.community.1}}</a>
|
||||
{{/if}}
|
||||
{{if $nav.introductions}}
|
||||
<a id="nav-notify-link" class="nav-commlink {{$nav.introductions.2}} {{$sel.introductions}}" href="{{$nav.introductions.0}}" title="{{$nav.introductions.3}}" >{{$nav.introductions.1}}</a>
|
||||
<span id="intro-update" class="nav-ajax-left"></span>
|
||||
{{/if}}
|
||||
{{if $nav.messages}}
|
||||
<a id="nav-messages-link" class="nav-commlink {{$nav.messages.2}} {{$sel.messages}}" href="{{$nav.messages.0}}" title="{{$nav.messages.3}}" >{{$nav.messages.1}}</a>
|
||||
<span id="mail-update" class="nav-ajax-left"></span>
|
||||
{{/if}}
|
||||
{{if $nav.notifications}}
|
||||
<a id="nav-notifications-linkmenu" class="nav-commlink" href="{{$nav.notifications.0}}" rel="#nav-notifications-menu" title="{{$nav.notifications.1}}">{{$nav.notifications.1}}</a>
|
||||
<span id="notify-update" class="nav-ajax-left"></span>
|
||||
<ul id="nav-notifications-menu" class="menu-popup">
|
||||
<li id="nav-notifications-see-all"><a href="{{$nav.notifications.all.0}}">{{$nav.notifications.all.1}}</a></li>
|
||||
<li id="nav-notifications-mark-all"><a href="#" onclick="notifyMarkAll(); return false;">{{$nav.notifications.mark.3}}</a></li>
|
||||
<li class="empty">{{$emptynotifications}}</li>
|
||||
</ul>
|
||||
{{/if}}
|
||||
</span>
|
||||
<span id="banner">{{$banner}}</span>
|
||||
<span id="nav-link-wrapper">
|
||||
{{if $nav.logout}}<a id="nav-logout-link" class="nav-link {{$nav.logout.2}}" href="{{$nav.logout.0}}" title="{{$nav.logout.3}}" >{{$nav.logout.1}}</a> {{/if}}
|
||||
{{if $nav.login}}<a id="nav-login-link" class="nav-login-link {{$nav.login.2}}" href="{{$nav.login.0}}" title="{{$nav.login.3}}" >{{$nav.login.1}}</a> {{/if}}
|
||||
{{if $nav.help}} <a id="nav-help-link" class="nav-link {{$nav.help.2}}" target="friendica-help" href="{{$nav.help.0}}" title="{{$nav.help.3}}" >{{$nav.help.1}}</a>{{/if}}
|
||||
|
||||
{{if $nav.apps}}<a id="nav-apps-link" class="nav-link {{$nav.apps.2}}" href="{{$nav.apps.0}}" title="{{$nav.apps.3}}" >{{$nav.apps.1}}</a>{{/if}}
|
||||
|
||||
<a id="nav-search-link" class="nav-link {{$nav.search.2}}" href="{{$nav.search.0}}" title="{{$nav.search.3}}" >{{$nav.search.1}}</a>
|
||||
<a id="nav-directory-link" class="nav-link {{$nav.directory.2}}" href="{{$nav.directory.0}}" title="{{$nav.directory.3}}" >{{$nav.directory.1}}</a>
|
||||
|
||||
{{if $nav.admin}}<a id="nav-admin-link" class="nav-link {{$nav.admin.2}}" href="{{$nav.admin.0}}" title="{{$nav.admin.3}}" >{{$nav.admin.1}}</a>{{/if}}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
{{if $nav.settings}}<a id="nav-settings-link" class="nav-link {{$nav.settings.2}}" href="{{$nav.settings.0}}" title="{{$nav.settings.3}}">{{$nav.settings.1}}</a>{{/if}}
|
||||
{{if $nav.profiles}}<a id="nav-profiles-link" class="nav-link {{$nav.profiles.2}}" href="{{$nav.profiles.0}}" title="{{$nav.profiles.3}}" >{{$nav.profiles.1}}</a>{{/if}}
|
||||
|
||||
{{if $nav.contacts}}<a id="nav-contacts-link" class="nav-link {{$nav.contacts.2}}" href="{{$nav.contacts.0}}" title="{{$nav.contacts.3}}" >{{$nav.contacts.1}}</a>{{/if}}
|
||||
|
||||
|
||||
{{if $nav.manage}}<a id="nav-manage-link" class="nav-link {{$nav.manage.2}} {{$sel.manage}}" href="{{$nav.manage.0}}" title="{{$nav.manage.3}}">{{$nav.manage.1}}</a>{{/if}}
|
||||
</span>
|
||||
<span id="nav-end"></span>
|
||||
|
||||
</nav>
|
||||
|
||||
<ul id="nav-notifications-template" style="display:none;" rel="template">
|
||||
<li class="{4}"><a href="{0}"><img data-src="{1}" height="24" width="24" alt="" />{2} <span class="notif-when">{3}</span></a></li>
|
||||
</ul>
|
||||
<script>
|
||||
var pagetitle = null;
|
||||
$("nav").bind('nav-update', function(e,data){
|
||||
if (pagetitle==null) pagetitle = document.title;
|
||||
var count = $(data).find('notif').attr('count');
|
||||
if (count>0) {
|
||||
document.title = "("+count+") "+pagetitle;
|
||||
} else {
|
||||
document.title = pagetitle;
|
||||
}
|
||||
});
|
||||
</script>
|
11
cleanzero/templates/theme_settings.tpl
Normal file
11
cleanzero/templates/theme_settings.tpl
Normal file
|
@ -0,0 +1,11 @@
|
|||
|
||||
{{include file="field_select.tpl" field=$color}}
|
||||
{{include file="field_select.tpl" field=$font_size}}
|
||||
{{include file="field_select.tpl" field=$resize}}
|
||||
{{include file="field_select.tpl" field=$theme_width}}
|
||||
|
||||
|
||||
<div class="settings-submit-wrapper">
|
||||
<input type="submit" value="{{$submit}}" class="settings-submit" name="cleanzero-settings-submit" />
|
||||
</div>
|
||||
|
126
cleanzero/theme.php
Normal file
126
cleanzero/theme.php
Normal file
|
@ -0,0 +1,126 @@
|
|||
<?php
|
||||
/*
|
||||
* Name: cleanzero
|
||||
* Description: Theme with clean design derived from the zero theme family. Including options to set color schemes, font sizes and resizing of images in posts
|
||||
* Version:
|
||||
* Author: Christian Vogeley (https://christian-vogeley.de/profile/christian)
|
||||
*/
|
||||
|
||||
function cleanzero_init(&$a) {
|
||||
$a->theme_info = array(
|
||||
'extends' => 'duepuntozero',
|
||||
);
|
||||
set_template_engine($a, 'smarty3');
|
||||
|
||||
$a->page['htmlhead'] .= <<< EOT
|
||||
<script>
|
||||
|
||||
function insertFormatting(comment,BBcode,id) {
|
||||
|
||||
var tmpStr = $("#comment-edit-text-" + id).val();
|
||||
if(tmpStr == comment) {
|
||||
tmpStr = "";
|
||||
$("#comment-edit-text-" + id).addClass("comment-edit-text-full");
|
||||
$("#comment-edit-text-" + id).removeClass("comment-edit-text-empty");
|
||||
openMenu("comment-edit-submit-wrapper-" + id);
|
||||
$("#comment-edit-text-" + id).val(tmpStr);
|
||||
}
|
||||
|
||||
textarea = document.getElementById("comment-edit-text-" +id);
|
||||
if (document.selection) {
|
||||
textarea.focus();
|
||||
selected = document.selection.createRange();
|
||||
if (BBcode == "url"){
|
||||
selected.text = "["+BBcode+"]" + "http://" + selected.text + "[/"+BBcode+"]";
|
||||
} else
|
||||
selected.text = "["+BBcode+"]" + selected.text + "[/"+BBcode+"]";
|
||||
} else if (textarea.selectionStart || textarea.selectionStart == "0") {
|
||||
var start = textarea.selectionStart;
|
||||
var end = textarea.selectionEnd;
|
||||
if (BBcode == "url"){
|
||||
textarea.value = textarea.value.substring(0, start) + "["+BBcode+"]" + "http://" + textarea.value.substring(start, end) + "[/"+BBcode+"]" + textarea.value.substring(end, textarea.value.length);
|
||||
} else
|
||||
textarea.value = textarea.value.substring(0, start) + "["+BBcode+"]" + textarea.value.substring(start, end) + "[/"+BBcode+"]" + textarea.value.substring(end, textarea.value.length);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
function cmtBbOpen(comment, id) {
|
||||
if($(comment).hasClass('comment-edit-text-full')) {
|
||||
$(".comment-edit-bb-" + id).show();
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
function cmtBbClose(comment, id) {
|
||||
// if($(comment).hasClass('comment-edit-text-empty')) {
|
||||
// $(".comment-edit-bb-" + id).hide();
|
||||
// return true;
|
||||
// }
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
$(document).ready(function() {
|
||||
|
||||
$('.group-edit-icon').hover(
|
||||
function() {
|
||||
$(this).addClass('icon'); $(this).removeClass('iconspacer');},
|
||||
function() {
|
||||
$(this).removeClass('icon'); $(this).addClass('iconspacer');}
|
||||
);
|
||||
|
||||
$('.sidebar-group-element').hover(
|
||||
function() {
|
||||
id = $(this).attr('id');
|
||||
$('#edit-' + id).addClass('icon'); $('#edit-' + id).removeClass('iconspacer');},
|
||||
|
||||
function() {
|
||||
id = $(this).attr('id');
|
||||
$('#edit-' + id).removeClass('icon');$('#edit-' + id).addClass('iconspacer');}
|
||||
);
|
||||
|
||||
|
||||
$('.savedsearchdrop').hover(
|
||||
function() {
|
||||
$(this).addClass('drop'); $(this).addClass('icon'); $(this).removeClass('iconspacer');},
|
||||
function() {
|
||||
$(this).removeClass('drop'); $(this).removeClass('icon'); $(this).addClass('iconspacer');}
|
||||
);
|
||||
|
||||
$('.savedsearchterm').hover(
|
||||
function() {
|
||||
id = $(this).attr('id');
|
||||
$('#drop-' + id).addClass('icon'); $('#drop-' + id).addClass('drophide'); $('#drop-' + id).removeClass('iconspacer');},
|
||||
|
||||
function() {
|
||||
id = $(this).attr('id');
|
||||
$('#drop-' + id).removeClass('icon');$('#drop-' + id).removeClass('drophide'); $('#drop-' + id).addClass('iconspacer');}
|
||||
);
|
||||
|
||||
});
|
||||
|
||||
|
||||
</script>
|
||||
EOT;
|
||||
// get resize configuration
|
||||
|
||||
$resize=false;
|
||||
$site_resize = get_config('cleanzero', 'resize' );
|
||||
if(local_user()) $resize = get_pconfig(local_user(), 'cleanzero', 'resize' );
|
||||
|
||||
if ($resize===false) $resize=$site_resize;
|
||||
if ($resize===false) $resize=0;
|
||||
|
||||
if (intval($resize) > 0) {
|
||||
//load jquery.ae.image.resize.js
|
||||
$imageresizeJS = $a->get_baseurl($ssl_state)."/view/theme/cleanzero/js/jquery.ae.image.resize.js";
|
||||
$a->page['htmlhead'] .= sprintf('<script language="JavaScript" src="%s" ></script>', $imageresizeJS);
|
||||
$a->page['htmlhead'] .= '
|
||||
<script>
|
||||
|
||||
$(function() {
|
||||
$(".wall-item-content img").aeImageResize({height: '.$resize.', width: '.$resize.'});
|
||||
});
|
||||
</script>';}
|
||||
}
|
0
cleanzero/unsupported
Normal file
0
cleanzero/unsupported
Normal file
Loading…
Add table
Add a link
Reference in a new issue