Permalink
Browse files

Make css id's more specific. If a class has functions named "header",…

…"nav","menu","main" etc. it would cause some interesting cssplosions
  • Loading branch information...
bluehawk committed Oct 20, 2010
1 parent fefe2ed commit 8a9489a8a8172b404f89e71bc8eb074bbd415251
Showing with 54 additions and 54 deletions.
  1. +46 −46 media/guide/css/kodoc.css
  2. +8 −8 views/userguide/template.php
View
@@ -118,11 +118,11 @@ h4 {
margin:1.5em 0;
}
-#main h2 {
+#kodoc-main h2 {
background:transparent url('../img/h2_line.png') bottom left repeat-x scroll;
}
-#main h3 {
+#kodoc-main h3 {
background:transparent url('../img/h3_line.png') bottom left repeat-x scroll;
}
@@ -156,7 +156,7 @@ h6:hover a.permalink {
display:inline;
}
-#main img {
+#kodoc-main img {
padding:1em;
outline:1px solid #999;
max-width:772px;
@@ -165,56 +165,56 @@ h6:hover a.permalink {
/* layout stuff */
-#header {
+#kodoc-header {
background:#85da4c url('../img/header.png') bottom left repeat-x scroll;
padding:20px 20px 0;
}
-#nav {
+#kodoc-nav {
background:url('../img/breadcrumbs.png') top left repeat-x scroll;
padding:10px 20px;
}
-#nav .container {
+#kodoc-nav .container {
margin:0 auto;
}
-#nav ul {
+#kodoc-nav ul {
float:left;
margin:0;
}
-#nav li {
+#kodoc-nav li {
display:inline-block;
margin-right:.6em;
float:left;
}
-#nav a {
+#kodoc-nav a {
font-weight:bold;
}
-#nav li:not(:first-child):before {
+#kodoc-nav li:not(:first-child):before {
content:'» ';
padding-right:.3em;
}
-#footer {
+#kodoc-footer {
margin:0 auto;
padding:0 20px;
width:1060px;
margin-bottom:20px;
}
-#footer p {
+#kodoc-footer p {
margin:0;
padding:1.5em 30px;
background:#eee;
border-radius:10px;
text-align:right;
}
-#body {
+#kodoc-body {
padding:0 20px;
}
@@ -223,41 +223,41 @@ h6:hover a.permalink {
margin:20px auto;
}
-#main {
+#kodoc-main {
float:left;
width:800px;
/* background:transparent url('../img/lines.png') top left repeat scroll; */
}
-#menu {
+#kodoc-menu {
border-left:2px solid #eee;
float:right;
margin:0 0 0 20px;
padding:0 20px;
width:198px;
}
- #menu ul , #menu ol{ list-style-type:none; margin: 0; padding: 0;}
- #menu ul li, #menu ol li { margin:0; padding: 0; background:url('../img/arrows.png') -80px -1px no-repeat scroll; padding-left:12px; position:relative; }
- #menu ul li.toggle-close, #menu ol li.toggle-close{ background-position: -22px -22px; }
- #menu ul li.toggle-open, #menu ol li.toggle-open { background-position: -2px -42px; }
- #menu ul li a.menu-toggle, #menu ol li a.menu-toggle { width:14px; height:18px; position:absolute; left:0px; text-decoration:none; cursor:pointer;}
- #menu ul li a.current, #menu ol li a.current {font-weight:bold;}
+ #kodoc-menu ul , #kodoc-menu ol{ list-style-type:none; margin: 0; padding: 0;}
+ #kodoc-menu ul li, #kodoc-menu ol li { margin:0; padding: 0; background:url('../img/arrows.png') -80px -1px no-repeat scroll; padding-left:12px; position:relative; }
+ #kodoc-menu ul li.toggle-close, #kodoc-menu ol li.toggle-close{ background-position: -22px -22px; }
+ #kodoc-menu ul li.toggle-open, #kodoc-menu ol li.toggle-open { background-position: -2px -42px; }
+ #kodoc-menu ul li a.menu-toggle, #kodoc-menu ol li a.menu-toggle { width:14px; height:18px; position:absolute; left:0px; text-decoration:none; cursor:pointer;}
+ #kodoc-menu ul li a.current, #kodoc-menu ol li a.current {font-weight:bold;}
- #menu li span { cursor:pointer; }
+ #kodoc-menu li span { cursor:pointer; }
-#header .container {
+#kodoc-header .container {
margin:0 auto 0;
position:relative;
padding:0 0 20px 0;
}
-#mode {
+#kodoc-tabs {
position:absolute;
bottom:0;
right:0;
}
-#mode a {
+#kodoc-tabs a {
background:#f3b812 url('../img/orange-tab.png') bottom left repeat-x scroll;
border:2px solid #fff;
border-bottom:none;
@@ -272,11 +272,11 @@ h6:hover a.permalink {
margin-right:10px;
}
-#mode a:hover {
+#kodoc-tabs a:hover {
background:#f3b812 url('../img/orange-tab.png') 10px left repeat-x scroll;
}
-#mode a.current {
+#kodoc-tabs a.current {
background:#fff;
color: #555555;
font-weight:bold;
@@ -285,36 +285,36 @@ h6:hover a.permalink {
/* Api browser stuff */
/* api index page */
-#main div.class-list div.class { width: 50%; }
-#main div.class-list div.class.left { float: left; clear: both; }
-#main div.class-list div.class.right { float: right; }
- #main div.class-list div.class h2 { background:none; }
+#kodoc-main div.class-list div.class { width: 50%; }
+#kodoc-main div.class-list div.class.left { float: left; clear: both; }
+#kodoc-main div.class-list div.class.right { float: right; }
+ #kodoc-main div.class-list div.class h2 { background:none; }
/* table of contents at the top of each class */
-#main div.toc { }
-#main div.toc div {float:left; width: 33%;}
-#main div.toc div h3 {margin-top:0; background:none; }
+#kodoc-main div.toc { }
+#kodoc-main div.toc div {float:left; width: 33%;}
+#kodoc-main div.toc div h3 {margin-top:0; background:none; }
/* constants */
-#main div.constants dl dt {font-weight:bold; margin-bottom:1.5em;}
-#main div.constants dl dd {margin-left:1.5em; margin-bottom:1.5em;}
+#kodoc-main div.constants dl dt {font-weight:bold; margin-bottom:1.5em;}
+#kodoc-main div.constants dl dd {margin-left:1.5em; margin-bottom:1.5em;}
/* properties */
-#main div.properties dl dt { font-weight:bold; margin-top:1.5em; margin-bottom:1.5em;}
-#main div.properties dl dt small, div.properties dl dt code { font-weight:normal; font-size:0.9em; }
-#main div.properties dl dd {margin-left:1.5em; margin-bottom:1.5em;}
+#kodoc-main div.properties dl dt { font-weight:bold; margin-top:1.5em; margin-bottom:1.5em;}
+#kodoc-main div.properties dl dt small, div.properties dl dt code { font-weight:normal; font-size:0.9em; }
+#kodoc-main div.properties dl dd {margin-left:1.5em; margin-bottom:1.5em;}
/* functions */
-#main div.method { padding:0 1.5em; border:1px solid #aaa; border-radius:5px; margin-bottom:1.5em; }
-#main div.method h3 { background:none; margin-top:0; margin-left:-1.17em; margin-right:-1.17em; padding:.75em 0 .75em 1.17em; background:#eee; border-top-left-radius:5px; border-top-right-radius:5px; }
-#main div.method h3 .param { font-weight: normal; cursor: help; border-bottom:1px dashed #666;}
-#main div.method h3 abbr.param { text-transform: none; font-size: 1em; }
+#kodoc-main div.method { padding:0 1.5em; border:1px solid #aaa; border-radius:5px; margin-bottom:1.5em; }
+#kodoc-main div.method h3 { background:none; margin-top:0; margin-left:-1.17em; margin-right:-1.17em; padding:.75em 0 .75em 1.17em; background:#eee; border-top-left-radius:5px; border-top-right-radius:5px; }
+#kodoc-main div.method h3 .param { font-weight: normal; cursor: help; border-bottom:1px dashed #666;}
+#kodoc-main div.method h3 abbr.param { text-transform: none; font-size: 1em; }
-#main dl.tags { overflow: auto; background: #eee; padding: 1em; border: solid 6px #ddd; margin-bottom:1.5em; }
- #main dl.tags dt { margin: 0; clear: both; float: left; width: 25%; }
- #main dl.tags dd { margin: 0; padding: 0; clear: right; float: right; }
+#kodoc-main dl.tags { overflow: auto; background: #eee; padding: 1em; border: solid 6px #ddd; margin-bottom:1.5em; }
+ #kodoc-main dl.tags dt { margin: 0; clear: both; float: left; width: 25%; }
+ #kodoc-main dl.tags dd { margin: 0; padding: 0; clear: right; float: right; }
.sourcecode-toggle {
margin-left:.3em;
@@ -16,19 +16,19 @@
</head>
<body>
- <div id="header">
+ <div id="kodoc-header">
<div class="container clearfix">
- <div id="logo">
+ <div id="kodoc-logo">
<?php echo HTML::image(Route::get('docs/media')->uri(array('file'=>'img/kohana.png'))) ?>
</div>
- <div id="mode">
+ <div id="kodoc-tabs">
<?php $route = Request::instance()->route; ?>
<?php echo HTML::anchor(Route::get('docs/guide')->uri(), 'User Guide',Route::get('docs/guide') == $route ? array('class' => 'current'):array()) ?>
<?php echo HTML::anchor(Route::get('docs/api')->uri(), 'API Browser',Route::get('docs/api') == $route ? array('class' => 'current'):array()) ?>
</div>
</div>
</div>
- <div id="nav">
+ <div id="kodoc-nav">
<div class="container clearfix">
<ul>
<?php foreach ($breadcrumb as $link => $title): ?>
@@ -37,8 +37,8 @@
</ul>
</div>
</div>
- <div class="container clearfix" id="body">
- <div id="main">
+ <div class="container clearfix" id="kodoc-body">
+ <div id="kodoc-main">
<?php echo $content ?>
<?php if (Kohana::$environment === Kohana::PRODUCTION): ?>
@@ -55,11 +55,11 @@
<a href="http://disqus.com" class="dsq-brlink">Documentation comments powered by <span class="logo-disqus">Disqus</span></a>
<?php endif ?>
</div>
- <div id="menu">
+ <div id="kodoc-menu">
<?php echo $menu ?>
</div>
</div>
- <div id="footer" style="overflow:hidden;">
+ <div id="kodoc-footer" style="overflow:hidden;">
<p>
<?php if (isset($copyright)) echo "<span style='float:left'>$copyright</span>"; ?>
Powered by <?php echo HTML::anchor('http://kohanaframework.org/', 'Kohana') ?> v<?php echo Kohana::VERSION ?>

0 comments on commit 8a9489a

Please sign in to comment.