]> git.plutz.net Git - shellwiki/blobdiff - themes/default.css
simplified code for editor help tabs
[shellwiki] / themes / default.css
index c4ebf6e447d4b36d30290e383b942ed0eb201024..1823d7781758e6db6227afb7e606c284faccb5fc 100644 (file)
@@ -111,59 +111,37 @@ main pre {
 
 /* === Editor === */
 
-body[id$="/[edit]"] textarea,
-body[id$="/[newpage]"] textarea {
+[id$="/[edit]"] main .pagemenu {
+  margin-bottom: 1em;
+}
+
+.tab[name=edithelp] ~ .tab.editor textarea {
   width: 100%;
   min-height: 20em; min-height: 50vh;
   font-family: monospace;
   font-size: inherit;
 }
-
-[id$="/[edit]"] main {
-  padding-top: 2.5em;
-}
-[id$="/[edit]"] input[type=radio].tab ~ div.tab.syntax,
-[id$="/[edit]"] input[type=radio].tab ~ div.tab.help,
-[id$="/[newpage]"] input[type=radio].tab ~ div.tab.syntax,
-[id$="/[newpage]"] input[type=radio].tab ~ div.tab.help {
+.tab[name=edithelp] ~ .tab.syntax,
+.tab[name=edithelp] ~ .tab.attach {
   background-color: #FFF;
   min-height: 20em; min-height: 50vh;
 }
-[id$="/[edit]"] input[type=radio].tab#edtr:checked ~ form.tab.editor,
-[id$="/[newpage]"] input[type=radio].tab#edtr:checked ~ form.tab.editor {
-  display: block;
-}
-[id$="/[edit]"] input[type=radio].tab#help:checked ~ div.tab.syntax,
-[id$="/[newpage]"] input[type=radio].tab#help:checked ~ div.tab.syntax {
-  display: block;
-}
-[id$="/[edit]"] input[type=radio].tab#himg:checked ~ div.tab.help,
-[id$="/[edit]"] input[type=radio].tab#hdoc:checked ~ div.tab.help,
-[id$="/[newpage]"] input[type=radio].tab#himg:checked ~ div.tab.help,
-[id$="/[newpage]"] input[type=radio].tab#hdoc:checked ~ div.tab.help {
-  display: block;
-}
-[id$="/[edit]"] input[type=radio].tab ~ div.tab.help .himg,
-[id$="/[edit]"] input[type=radio].tab ~ div.tab.help .hdoc,
-[id$="/[newpage]"] input[type=radio].tab ~ div.tab.help .himg,
-[id$="/[newpage]"] input[type=radio].tab ~ div.tab.help .hdoc {
-  display: none;
-}
-[id$="/[edit]"] input[type=radio].tab ~ div.tab.help,
-[id$="/[newpage]"] input[type=radio].tab ~ div.tab.help {
+
+.tab[name=edithelp] ~ .tab.attach {
   padding-top: 1em;
   padding-left: 7em;
 }
-[id$="/[edit]"] input[type=radio].tab ~ div.tab.help .himg img,
-[id$="/[newpage]"] input[type=radio].tab ~ div.tab.help .himg img {
+.tab[name=edithelp] ~ .tab.attach .aimg img {
   float: left;
   max-height: 4em;
   margin-left: -6em;
 }
-[id$="/[edit]"] input[type=radio].tab#himg:checked ~ div.tab.help .himg,
-[id$="/[newpage]"] input[type=radio].tab#himg:checked ~ div.tab.help .himg { display: block; }
-[id$="/[edit]"] input[type=radio].tab#hdoc:checked ~ div.tab.help .hdoc,
-[id$="/[newpage]"] input[type=radio].tab#hdoc:checked ~ div.tab.help .hdoc { display: block; }
+
+.tab[name=edithelp]#editor:checked ~ .tab.editor,
+.tab[name=edithelp]#syntax:checked ~ .tab.syntax,
+.tab[name=edithelp]#attach:checked ~ .tab.attach {
+  display: block;
+}
 
 
 /* === Attachments === */