First commit
This commit is contained in:
commit
c6e2478c40
13918 changed files with 2303184 additions and 0 deletions
BIN
themes/bartik/color/base.png
Normal file
BIN
themes/bartik/color/base.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 106 B |
132
themes/bartik/color/color.inc
Normal file
132
themes/bartik/color/color.inc
Normal file
|
@ -0,0 +1,132 @@
|
|||
<?php
|
||||
|
||||
// Put the logo path into JavaScript for the live preview.
|
||||
drupal_add_js(array('color' => array('logo' => theme_get_setting('logo', 'bartik'))), 'setting');
|
||||
|
||||
$info = array(
|
||||
// Available colors and color labels used in theme.
|
||||
'fields' => array(
|
||||
'top' => t('Header top'),
|
||||
'bottom' => t('Header bottom'),
|
||||
'bg' => t('Main background'),
|
||||
'sidebar' => t('Sidebar background'),
|
||||
'sidebarborders' => t('Sidebar borders'),
|
||||
'footer' => t('Footer background'),
|
||||
'titleslogan' => t('Title and slogan'),
|
||||
'text' => t('Text color'),
|
||||
'link' => t('Link color'),
|
||||
),
|
||||
// Pre-defined color schemes.
|
||||
'schemes' => array(
|
||||
'default' => array(
|
||||
'title' => t('Blue Lagoon (default)'),
|
||||
'colors' => array(
|
||||
'top' => '#0779bf',
|
||||
'bottom' => '#48a9e4',
|
||||
'bg' => '#ffffff',
|
||||
'sidebar' => '#f6f6f2',
|
||||
'sidebarborders' => '#f9f9f9',
|
||||
'footer' => '#292929',
|
||||
'titleslogan' => '#fffeff',
|
||||
'text' => '#3b3b3b',
|
||||
'link' => '#0071B3',
|
||||
),
|
||||
),
|
||||
'firehouse' => array(
|
||||
'title' => t('Firehouse'),
|
||||
'colors' => array(
|
||||
'top' => '#cd2d2d',
|
||||
'bottom' => '#cf3535',
|
||||
'bg' => '#ffffff',
|
||||
'sidebar' => '#f1f4f0',
|
||||
'sidebarborders' => '#ededed',
|
||||
'footer' => '#1f1d1c',
|
||||
'titleslogan' => '#fffeff',
|
||||
'text' => '#3b3b3b',
|
||||
'link' => '#d6121f',
|
||||
),
|
||||
),
|
||||
'ice' => array(
|
||||
'title' => t('Ice'),
|
||||
'colors' => array(
|
||||
'top' => '#d0d0d0',
|
||||
'bottom' => '#c2c4c5',
|
||||
'bg' => '#ffffff',
|
||||
'sidebar' => '#ffffff',
|
||||
'sidebarborders' => '#cccccc',
|
||||
'footer' => '#24272c',
|
||||
'titleslogan' => '#000000',
|
||||
'text' => '#4a4a4a',
|
||||
'link' => '#019dbf',
|
||||
),
|
||||
),
|
||||
'plum' => array(
|
||||
'title' => t('Plum'),
|
||||
'colors' => array(
|
||||
'top' => '#4c1c58',
|
||||
'bottom' => '#593662',
|
||||
'bg' => '#fffdf7',
|
||||
'sidebar' => '#edede7',
|
||||
'sidebarborders' => '#e7e7e7',
|
||||
'footer' => '#2c2c28',
|
||||
'titleslogan' => '#ffffff',
|
||||
'text' => '#301313',
|
||||
'link' => '#9d408d',
|
||||
),
|
||||
),
|
||||
'slate' => array(
|
||||
'title' => t('Slate'),
|
||||
'colors' => array(
|
||||
'top' => '#4a4a4a',
|
||||
'bottom' => '#4e4e4e',
|
||||
'bg' => '#ffffff',
|
||||
'sidebar' => '#ffffff',
|
||||
'sidebarborders' => '#d0d0d0',
|
||||
'footer' => '#161617',
|
||||
'titleslogan' => '#ffffff',
|
||||
'text' => '#3b3b3b',
|
||||
'link' => '#0073b6',
|
||||
),
|
||||
),
|
||||
),
|
||||
|
||||
// CSS files (excluding @import) to rewrite with new color scheme.
|
||||
'css' => array(
|
||||
'css/colors.css',
|
||||
),
|
||||
|
||||
// Files to copy.
|
||||
'copy' => array(
|
||||
'logo.png',
|
||||
),
|
||||
|
||||
// Gradient definitions.
|
||||
'gradients' => array(
|
||||
array(
|
||||
// (x, y, width, height).
|
||||
'dimension' => array(0, 0, 0, 0),
|
||||
// Direction of gradient ('vertical' or 'horizontal').
|
||||
'direction' => 'vertical',
|
||||
// Keys of colors to use for the gradient.
|
||||
'colors' => array('top', 'bottom'),
|
||||
),
|
||||
),
|
||||
|
||||
// Color areas to fill (x, y, width, height).
|
||||
'fill' => array(),
|
||||
|
||||
// Coordinates of all the theme slices (x, y, width, height)
|
||||
// with their filename as used in the stylesheet.
|
||||
'slices' => array(),
|
||||
|
||||
// Reference color used for blending. Matches the base.png's colors.
|
||||
'blend_target' => '#ffffff',
|
||||
|
||||
// Preview files.
|
||||
'preview_css' => 'color/preview.css',
|
||||
'preview_js' => 'color/preview.js',
|
||||
'preview_html' => 'color/preview.html',
|
||||
|
||||
// Base file for image generation.
|
||||
'base_image' => 'color/base.png',
|
||||
);
|
200
themes/bartik/color/preview.css
Normal file
200
themes/bartik/color/preview.css
Normal file
|
@ -0,0 +1,200 @@
|
|||
|
||||
/* ---------- Color form ----------- */
|
||||
#color_scheme_form #palette .form-item {
|
||||
width: 25em;
|
||||
}
|
||||
#color_scheme_form #palette .form-item label {
|
||||
width: 15em;
|
||||
}
|
||||
|
||||
/* ---------- Preview Styles ----------- */
|
||||
|
||||
html.js #preview {
|
||||
clear: both;
|
||||
float: none !important;
|
||||
}
|
||||
#preview {
|
||||
background-color: #fff;
|
||||
font-family: Georgia, "Times New Roman", Times, serif;
|
||||
font-size: 14px;
|
||||
line-height: 1.5;
|
||||
overflow: hidden;
|
||||
word-wrap: break-word;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
#preview-header {
|
||||
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
|
||||
position: relative;
|
||||
}
|
||||
#preview-logo {
|
||||
float: left;
|
||||
padding: 15px 15px 15px 10px;
|
||||
}
|
||||
#preview-site-name {
|
||||
color: #686868;
|
||||
font-weight: normal;
|
||||
font-size: 1.821em;
|
||||
line-height: 1;
|
||||
margin-bottom: 30px;
|
||||
margin-left: 15px;
|
||||
padding-top: 34px;
|
||||
}
|
||||
#preview-main-menu {
|
||||
clear: both;
|
||||
padding: 0 15px 3px;
|
||||
}
|
||||
#preview-main-menu-links a {
|
||||
color: #d9d9d9;
|
||||
padding: 0.6em 1em 0.4em;
|
||||
}
|
||||
#preview-main-menu-links {
|
||||
font-size: 0.929em;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
#preview-main-menu-links a {
|
||||
color: #333;
|
||||
background: #ccc;
|
||||
background: rgba(255, 255, 255, 0.7);
|
||||
text-shadow: 0 1px #eee;
|
||||
-khtml-border-radius-topleft: 8px;
|
||||
-moz-border-radius-topleft: 8px;
|
||||
-webkit-border-top-left-radius: 8px;
|
||||
border-top-left-radius: 8px;
|
||||
-khtml-border-radius-topright: 8px;
|
||||
-moz-border-radius-topright: 8px;
|
||||
-webkit-border-top-right-radius: 8px;
|
||||
border-top-right-radius: 8px;
|
||||
}
|
||||
#preview-main-menu-links a:hover,
|
||||
#preview-main-menu-links a:focus {
|
||||
background: #fff;
|
||||
background: rgba(255, 255, 255, 0.95);
|
||||
}
|
||||
#preview-main-menu-links a:active {
|
||||
background: #b3b3b3;
|
||||
background: rgba(255, 255, 255, 1);
|
||||
}
|
||||
#preview-main-menu-links li a.active {
|
||||
border-bottom: none;
|
||||
}
|
||||
#preview-main-menu-links li {
|
||||
display: inline;
|
||||
list-style-type: none;
|
||||
padding: 0.6em 0 0.4em;
|
||||
}
|
||||
#preview-sidebar,
|
||||
#preview-content {
|
||||
display: inline;
|
||||
float: left;
|
||||
position: relative;
|
||||
}
|
||||
#preview-sidebar {
|
||||
margin-left: 15px;
|
||||
width: 210px;
|
||||
}
|
||||
#preview-content {
|
||||
margin-left: 30px;
|
||||
width: 26.5em;
|
||||
}
|
||||
#preview-sidebar .preview-block {
|
||||
border: 1px solid;
|
||||
margin: 20px 0;
|
||||
padding: 15px 20px;
|
||||
}
|
||||
#preview-sidebar h2 {
|
||||
border-bottom: 1px solid #d6d6d6;
|
||||
font-size: 1.071em;
|
||||
font-weight: normal;
|
||||
line-height: 1.2;
|
||||
margin: 0 0 0.5em;
|
||||
padding-bottom: 5px;
|
||||
text-shadow: 0 1px 0 #fff;
|
||||
}
|
||||
#preview .preview-block .preview-content {
|
||||
margin-top: 1em;
|
||||
}
|
||||
#preview .preview-block-menu .preview-content,
|
||||
#preview .preview-block-menu .preview-content ul {
|
||||
margin-top: 0;
|
||||
}
|
||||
#preview-main {
|
||||
margin-bottom: 40px;
|
||||
margin-top: 20px;
|
||||
}
|
||||
#preview-page-title {
|
||||
font-size: 2em;
|
||||
font-weight: normal;
|
||||
line-height: 1;
|
||||
margin: 1em 0 0.5em;
|
||||
}
|
||||
#preview-footer-wrapper {
|
||||
color: #c0c0c0;
|
||||
color: rgba(255, 255, 255, 0.65);
|
||||
display: block !important;
|
||||
font-size: 0.857em;
|
||||
padding: 20px 20px 25px;
|
||||
}
|
||||
#preview-footer-wrapper a {
|
||||
color: #fcfcfc;
|
||||
color: rgba(255, 255, 255, 0.8);
|
||||
}
|
||||
#preview-footer-wrapper a:hover,
|
||||
#preview-footer-wrapper a:focus {
|
||||
color: #fefefe;
|
||||
color: rgba(255, 255, 255, 0.95);
|
||||
text-decoration: underline;
|
||||
}
|
||||
#preview-footer-wrapper .preview-footer-column {
|
||||
display: inline;
|
||||
float: left;
|
||||
padding: 0 10px;
|
||||
position: relative;
|
||||
width: 220px;
|
||||
}
|
||||
#preview-footer-wrapper .preview-block {
|
||||
border: 1px solid #444;
|
||||
border-color: rgba(255, 255, 255, 0.1);
|
||||
margin: 20px 0;
|
||||
padding: 10px;
|
||||
}
|
||||
#preview-footer-columns .preview-block-menu {
|
||||
border: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
#preview-footer-columns h2 {
|
||||
border-bottom: 1px solid #555;
|
||||
border-color: rgba(255, 255, 255, 0.15);
|
||||
font-size: 1em;
|
||||
margin-bottom: 0;
|
||||
padding-bottom: 3px;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
#preview-footer-columns .preview-content {
|
||||
margin-top: 0;
|
||||
}
|
||||
#preview-footer-columns .preview-content ul {
|
||||
margin-left: 0;
|
||||
padding-left: 0;
|
||||
}
|
||||
#preview-footer-columns .preview-content li {
|
||||
list-style: none;
|
||||
list-style-image: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
#preview-footer-columns .preview-content li a {
|
||||
border-bottom: 1px solid #555;
|
||||
border-color: rgba(255, 255, 255, 0.15);
|
||||
display: block;
|
||||
line-height: 1.2;
|
||||
padding: 0.8em 2px 0.8em 20px;
|
||||
text-indent: -15px;
|
||||
}
|
||||
#preview-footer-columns .preview-content li a:hover,
|
||||
#preview-footer-columns .preview-content li a:focus {
|
||||
background-color: #1f1f21;
|
||||
background-color: rgba(255, 255, 255, 0.05);
|
||||
text-decoration: none;
|
||||
}
|
65
themes/bartik/color/preview.html
Normal file
65
themes/bartik/color/preview.html
Normal file
|
@ -0,0 +1,65 @@
|
|||
<div id="preview">
|
||||
|
||||
<div id="preview-header">
|
||||
<div id="preview-logo"><img src="../../../themes/bartik/logo.png" alt="Site Logo" /></div>
|
||||
<div id="preview-site-name">Bartik</div>
|
||||
<div id="preview-main-menu">
|
||||
<ul id="preview-main-menu-links">
|
||||
<li><a>Home</a></li>
|
||||
<li><a>Te Quidne</a></li>
|
||||
<li><a>Vel Torqueo Quae Erat</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="preview-main" class="clearfix">
|
||||
<div id="preview-sidebar">
|
||||
<div id="preview-block" class="preview-block">
|
||||
<h2>Etiam est risus</h2>
|
||||
<div class="preview-content">
|
||||
Maecenas id porttitor Ut enim ad minim veniam, quis nostrudfelis.
|
||||
Laboris nisi ut aliquip ex ea.
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="preview-content">
|
||||
<h1 id="preview-page-title">Lorem ipsum dolor</h1>
|
||||
<div id="preview-node">
|
||||
<div class="preview-content">
|
||||
Sit amet, <a>consectetur adipisicing elit</a>, sed do eiusmod tempor
|
||||
incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis
|
||||
nostrud <a>exercitation ullamco</a> laboris nisi ut aliquip ex ea
|
||||
commodo consequat. Maecenas id porttitor Ut enim ad minim veniam, quis nostr udfelis.
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="preview-footer-wrapper">
|
||||
<div id="preview-footer-columns" class="clearfix">
|
||||
<div class="preview-footer-column">
|
||||
<div class="preview-block">
|
||||
<h2>Etiam est risus</h2>
|
||||
<div class="content">
|
||||
Maecenas id porttitor Ut enim ad minim veniam, quis nostrudfelis.
|
||||
Laboris nisi ut aliquip ex ea.
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="preview-footer-column">
|
||||
<div class="preview-block preview-block-menu">
|
||||
<h2>Erisus dolor</h2>
|
||||
<div class="preview-content">
|
||||
<ul>
|
||||
<li><a>Donec placerat</a></li>
|
||||
<li><a>Nullam nibh dolor</a></li>
|
||||
<li><a>Blandit sed</a></li>
|
||||
<li><a>Fermentum id</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
39
themes/bartik/color/preview.js
Normal file
39
themes/bartik/color/preview.js
Normal file
|
@ -0,0 +1,39 @@
|
|||
|
||||
(function ($) {
|
||||
Drupal.color = {
|
||||
logoChanged: false,
|
||||
callback: function(context, settings, form, farb, height, width) {
|
||||
// Change the logo to be the real one.
|
||||
if (!this.logoChanged) {
|
||||
$('#preview #preview-logo img').attr('src', Drupal.settings.color.logo);
|
||||
this.logoChanged = true;
|
||||
}
|
||||
// Remove the logo if the setting is toggled off.
|
||||
if (Drupal.settings.color.logo == null) {
|
||||
$('div').remove('#preview-logo');
|
||||
}
|
||||
|
||||
// Solid background.
|
||||
$('#preview', form).css('backgroundColor', $('#palette input[name="palette[bg]"]', form).val());
|
||||
|
||||
// Text preview.
|
||||
$('#preview #preview-main h2, #preview .preview-content', form).css('color', $('#palette input[name="palette[text]"]', form).val());
|
||||
$('#preview #preview-content a', form).css('color', $('#palette input[name="palette[link]"]', form).val());
|
||||
|
||||
// Sidebar block.
|
||||
$('#preview #preview-sidebar #preview-block', form).css('background-color', $('#palette input[name="palette[sidebar]"]', form).val());
|
||||
$('#preview #preview-sidebar #preview-block', form).css('border-color', $('#palette input[name="palette[sidebarborders]"]', form).val());
|
||||
|
||||
// Footer wrapper background.
|
||||
$('#preview #preview-footer-wrapper', form).css('background-color', $('#palette input[name="palette[footer]"]', form).val());
|
||||
|
||||
// CSS3 Gradients.
|
||||
var gradient_start = $('#palette input[name="palette[top]"]', form).val();
|
||||
var gradient_end = $('#palette input[name="palette[bottom]"]', form).val();
|
||||
|
||||
$('#preview #preview-header', form).attr('style', "background-color: " + gradient_start + "; background-image: -webkit-gradient(linear, 0% 0%, 0% 100%, from(" + gradient_start + "), to(" + gradient_end + ")); background-image: -moz-linear-gradient(-90deg, " + gradient_start + ", " + gradient_end + ");");
|
||||
|
||||
$('#preview #preview-site-name', form).css('color', $('#palette input[name="palette[titleslogan]"]', form).val());
|
||||
}
|
||||
};
|
||||
})(jQuery);
|
BIN
themes/bartik/color/preview.png
Normal file
BIN
themes/bartik/color/preview.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 106 B |
Loading…
Add table
Add a link
Reference in a new issue