From 63c5934de22932e6a7209d6c87f5d08a694b03fc Mon Sep 17 00:00:00 2001 From: Zaphod Date: Fri, 2 Mar 2012 21:18:44 +0000 Subject: feature 2587: new theme elegant, first beta version git-svn-id: http://piwigo.org/svn/trunk@13464 68402e56-0260-453c-a942-63ccdbb3a9ee --- themes/elegant/index.php | 30 +++++++ themes/elegant/local_head.tpl | 1 + themes/elegant/mail-css.tpl | 9 +++ themes/elegant/screenshot.png | Bin 0 -> 62117 bytes themes/elegant/scripts.js | 77 ++++++++++++++++++ themes/elegant/theme.css | 170 +++++++++++++++++++++++++++++++++++++++ themes/elegant/themeconf.inc.php | 15 ++++ 7 files changed, 302 insertions(+) create mode 100644 themes/elegant/index.php create mode 100644 themes/elegant/local_head.tpl create mode 100644 themes/elegant/mail-css.tpl create mode 100644 themes/elegant/screenshot.png create mode 100644 themes/elegant/scripts.js create mode 100644 themes/elegant/theme.css create mode 100644 themes/elegant/themeconf.inc.php (limited to 'themes') diff --git a/themes/elegant/index.php b/themes/elegant/index.php new file mode 100644 index 000000000..0e75275a1 --- /dev/null +++ b/themes/elegant/index.php @@ -0,0 +1,30 @@ + diff --git a/themes/elegant/local_head.tpl b/themes/elegant/local_head.tpl new file mode 100644 index 000000000..8279d6f15 --- /dev/null +++ b/themes/elegant/local_head.tpl @@ -0,0 +1 @@ +{combine_script id='elegant.scripts' require='jquery' path='themes/elegant/scripts.js'} diff --git a/themes/elegant/mail-css.tpl b/themes/elegant/mail-css.tpl new file mode 100644 index 000000000..6399c9efd --- /dev/null +++ b/themes/elegant/mail-css.tpl @@ -0,0 +1,9 @@ +/* Theme dark mail css */ + +body {ldelim} background-color:#444; color:#fff;} +#copyright {ldelim} color: #69c;} +h2 {ldelim} background-color: #333; color:#fff48e;} +img {ldelim} margin: 16px; border: 16px solid #111; -moz-border-radius: 4px; border-radius: 4px 4px; } +img:hover {ldelim} padding: 15px; border: 1px solid yellow;background-color:#444;-moz-border-radius: 4px; border-radius: 4px 4px; } +a {ldelim} color: #fff48e; background: transparent;border-bottom:1px dotted #005e89; } +a:hover {ldelim} color: #fff48e;} diff --git a/themes/elegant/screenshot.png b/themes/elegant/screenshot.png new file mode 100644 index 000000000..8886060b1 Binary files /dev/null and b/themes/elegant/screenshot.png differ diff --git a/themes/elegant/scripts.js b/themes/elegant/scripts.js new file mode 100644 index 000000000..e83dfd4f3 --- /dev/null +++ b/themes/elegant/scripts.js @@ -0,0 +1,77 @@ +jQuery("document").ready(function(jQuery){ + + var menubar=jQuery("#menubar"); + var content=jQuery("#content"); + + if ( (menubar.length == 1) && (content.length ==1)) { + menubar.after("
«
"); +/* if (!content.hasClass('content')) content.addClass('content');*/ + } + /*»*/ + + jQuery("#menuswitcher").click(function(){ + if (jQuery("#menubar").is(":hidden")) { + showMenu(0); + return false; + } else { + hideMenu(0); + return false; + } + }); + + // creates a variable with the contents of the cookie side-menu + var sidemenu = jQuery.cookie('side-menu'); + + // if cookie says the menu is hiding, keep it hidden! + if (sidemenu == 'hiding') { + hideMenu(0); + } else { + showMenu(0); + } + + +}); + +function hideMenu(delay) { + + var menubar=jQuery("#menubar"); + var menuswitcher=jQuery("#menuswitcher"); + var content=jQuery("#the_page > .content"); + var pcontent=jQuery("#content"); + + menubar.hide(delay); + menuswitcher.addClass("menuhidden").removeClass("menushown"); + menuswitcher.text("»"); + content.addClass("menuhidden").removeClass("menushown"); + pcontent.addClass("menuhidden").removeClass("menushown"); + jQuery.cookie('side-menu', 'hiding', {path: "/"}); + +} + +function showMenu(delay) { + + var menubar=jQuery("#menubar"); + var menuswitcher=jQuery("#menuswitcher"); + var content=jQuery("#the_page > .content"); + var pcontent=jQuery("#content"); + + menubar.show(delay); + menuswitcher.addClass("menushown").removeClass("menuhidden"); + menuswitcher.text("«"); + content.addClass("menushown").removeClass("menuhidden"); + pcontent.addClass("menushown").removeClass("menuhidden"); + jQuery.cookie('side-menu', 'showing', {path: "/"}); + +} + +/** + * Cookie plugin + * Copyright (c) 2006 Klaus Hartl (stilbuero.de) + * Dual licensed under the MIT and GPL licenses: + */ +jQuery.cookie=function(name,value,options){if(typeof value!='undefined'){options=options||{};if(value===null){value='';options=jQuery.extend({},options);options.expires=-1;} +var expires='';if(options.expires&&(typeof options.expires=='number'||options.expires.toUTCString)){var date;if(typeof options.expires=='number'){date=new Date();date.setTime(date.getTime()+(options.expires*24*60*60*1000));}else{date=options.expires;} +expires='; expires='+date.toUTCString();} +var path=options.path?'; path='+(options.path):'';var domain=options.domain?'; domain='+(options.domain):'';var secure=options.secure?'; secure':'';document.cookie=[name,'=',encodeURIComponent(value),expires,path,domain,secure].join('');}else{var cookieValue=null;if(document.cookie&&document.cookie!=''){var cookies=document.cookie.split(';');for(var i=0;i .content.menushown { margin-left:240px;} +#content.menuhidden, #the_page > .content.menuhidden { margin-left:35px;} +#content, #the_page > .content { margin-right:0;} + +.content { + background-color: #222; + border-bottom: 2px solid #444; + margin-bottom: 4px; +} + +.content .titrePage { + background-color: #111; + border-bottom: 2px solid #444; + height: 28px; + padding:0; + margin-bottom:8px; +} + +.content .titrePage H2 { + line-height: 20px; + margin: 0; + padding: 8px 0 0 2px; +} + + +body { color: #999;} +a { color: #ccc;} +a:hover { color: #fff;} + + + +/* menubar */ + +#menubar { + float: left; + margin: 28px 13px 10px 0; + padding: 0; + display: inline; + width: 225px; +} + +#menubar DT { color: #999; text-align:left;} +#menubar DT a { color: #ccc;} +#menubar DT a:hover { color: #fff;} +#menubar dd { padding: 0 0 1em 1em;} + +/* text color */ +BODY, H1, H3, +INPUT.rateButtonSelected /* <= why IE doesn't inherit this ? */ { + color:#d0d0d0; +} + +#menubar .pwg-icon-filter {display:none;} + + + + +/* backgrounds */ + +h3, #imageToolBar A:hover { + background-color: #2f2f2f; +} + +#imageToolBar, #imageHeaderBar, #derivativeSwitchLink, #derivativeSwitchBox, #sortOrderBox, .header_notes { + background-color: #505050; +} + +#imageHeaderBar H2 { + background-image: none; +} + +#imageHeaderBar { + border-top: 1px solid #000; +} + +/* borders */ +#derivativeSwitchLink, #derivativeSwitchBox, #sortOrderBox{ + border: 1px solid #000; +} + +#imageToolBar { + border-bottom: 1px solid #000; +} + +FIELDSET, INPUT, SELECT, TEXTAREA { + border: 1px solid gray; +} + + +/* picture page */ +#thePicturePage {background-color:#111;} +#imageHeaderBar { + border: solid 0 #444; + padding:0 35px; +} +#content #imageHeaderBar {padding:0;} +#copyright {border-top-width:2px;} +#imageHeaderBar {border-bottom-width:2px; width:auto;} +#imageHeaderBar, #imageToolBar, #copyright {background:none;} +#imageToolBar {margin-top: -28px;} +#theImage, #imageInfos, #comments {background:#222;} +#theImage {padding-top:10px;} +#imageHeaderBar { height:28px;} +#imageHeaderBar .browsePath {display:inline-block; float:none; font-size:120%; line-height:20px; padding: 8px 0 0 2px; font-weight:bold; margin:0;} +#imageHeaderBar .imageNumber {display:inline-block; float:none; line-height:20px; padding: 8px 0 0 12px; font-weight:bold; margin:0;} +#imageHeaderBar .imageNumber:before {content:'['} +#imageHeaderBar .imageNumber:after {content:']'} +#imageHeaderBar h2 {display:none;} +#thePicturePage .pwg-button {width:26px;} +#thePicturePage .actionButtons {margin-right: 26px;} +#imageToolBar {float:right;} + +#thePicturePage #comments {padding-top:12px; padding-bottom:12px;} +#thePicturePage #comments fieldset{margin-top: 0; margin-bottom:0;} +#copyright {padding-top:4px; text-align:right;} + + +.thumbnailCategory {background-color: #303030;} +#the_page .content .stuffs {margin:0!important} + +/* links */ +INPUT.rateButton { + color: #fff; +} + +.pwg-icon { + background-image: url(../default/s26/outline_ffffff.png); +} + +A:hover .pwg-icon { + background-image: url(../default/s26/outline_ffff80.png); +} + +.message { + color:white; + background-color:#666; +} \ No newline at end of file diff --git a/themes/elegant/themeconf.inc.php b/themes/elegant/themeconf.inc.php new file mode 100644 index 000000000..e4383e31e --- /dev/null +++ b/themes/elegant/themeconf.inc.php @@ -0,0 +1,15 @@ + 'elegant', + 'parent' => 'default', + 'local_head' => 'local_head.tpl' +); +?> -- cgit v1.2.3