[#369] small highlighting changes

This commit is contained in:
Alexander Machehin 2014-04-18 14:51:24 +06:00
parent e9156baa25
commit 628b69e22b
5 changed files with 95 additions and 86 deletions

View File

@ -1,5 +1,5 @@
= javascript_include_tag 'codemirror_editor' = javascript_include_tag 'codemirror_editor'
= stylesheet_link_tag 'codemirror' = stylesheet_link_tag 'codemirror_editor'
%h3= t("layout.projects.files_in_project") %h3= t("layout.projects.files_in_project")
.files .files

View File

@ -65,7 +65,7 @@ Rosa::Application.configure do
# Precompile additional assets (application.js, application.css, and all non-JS/CSS are already added) # Precompile additional assets (application.js, application.css, and all non-JS/CSS are already added)
config.assets.precompile += config.assets.precompile +=
%w(login.css login.js reg_session.css tour.css tour.js gollum/editor/langs/*.js moment/ru.js %w(login.css login.js reg_session.css tour.css tour.js gollum/editor/langs/*.js moment/ru.js
codemirror_editor.js codemirror.css) codemirror_editor.js codemirror_editor.css)
# Compress JavaScripts and CSS. # Compress JavaScripts and CSS.
config.assets.js_compressor = :uglifier config.assets.js_compressor = :uglifier

View File

@ -0,0 +1,7 @@
@import "codemirror";
.cm-s-default span.cm-preamble, {color: #b26818; font-weight: bold;}
.cm-s-default span.cm-macro {color: #b218b2;}
.cm-s-default span.cm-section {color: green; font-weight: bold;}
.cm-s-default span.cm-script {color: red;}
.cm-s-default span.cm-issue {color: yellow;}

View File

@ -47,11 +47,11 @@
margin: 0; margin: 0;
padding: 0.08em 0 0 0; padding: 0.08em 0 0 0;
} }
#head ul.actions { #head ul.actions {
float: right; float: right;
} }
/* @section content */ /* @section content */
//#wiki-content { //#wiki-content {
// height: 1%; // height: 1%;
@ -79,7 +79,7 @@
// .has-rightbar #wiki-body { // .has-rightbar #wiki-body {
// width: 68%; // width: 68%;
// } // }
/* @section rightbar */ /* @section rightbar */
#wiki-rightbar { #wiki-rightbar {
background-color: #f7f7f7; background-color: #f7f7f7;
@ -88,12 +88,12 @@
float: right; float: right;
padding: 7px; padding: 7px;
width: 25%; width: 25%;
border-radius: 0.5em; border-radius: 0.5em;
-moz-border-radius: 0.5em; -moz-border-radius: 0.5em;
-webkit-border-radius: 0.5em; -webkit-border-radius: 0.5em;
} }
#wiki-rightbar p { #wiki-rightbar p {
margin: 13px 0 0; margin: 13px 0 0;
} }
@ -109,13 +109,13 @@
padding: 0 0 0.5em 0; padding: 0 0 0.5em 0;
text-shadow: 0 1px 0 #fff; text-shadow: 0 1px 0 #fff;
} }
/* Back arrow */ /* Back arrow */
#wiki-rightbar p.parent:before { #wiki-rightbar p.parent:before {
color: #666; color: #666;
content: ""; content: "";
} }
#wiki-rightbar h3 { #wiki-rightbar h3 {
font-size: 1.2em; font-size: 1.2em;
color: #333; color: #333;
@ -123,12 +123,12 @@
padding: 0; padding: 0;
text-shadow: 0 1px 0 #fff; text-shadow: 0 1px 0 #fff;
} }
#wiki-rightbar ul { #wiki-rightbar ul {
margin: 0.5em 0 1em; margin: 0.5em 0 1em;
padding: 0; padding: 0;
} }
#wiki-rightbar ul li { #wiki-rightbar ul li {
color: #bbb; color: #bbb;
margin: 0 0 0 1em; margin: 0 0 0 1em;
@ -136,19 +136,19 @@
line-height: 1.75em; line-height: 1.75em;
list-style-position: inside; list-style-position: inside;
list-style-type: round; list-style-type: round;
} }
#wiki-rightbar #nav ul li a { #wiki-rightbar #nav ul li a {
font-weight: bold; font-weight: bold;
text-shadow: 0 1px 0 #fff; text-shadow: 0 1px 0 #fff;
} }
/* @section footer */ /* @section footer */
#wiki-footer { #wiki-footer {
clear: both; clear: both;
margin: 2em 0 5em; margin: 2em 0 5em;
} }
.has-rightbar #wiki-footer { .has-rightbar #wiki-footer {
width: 70%; width: 70%;
} }
@ -160,18 +160,18 @@
padding: 0 0 0.2em; padding: 0 0 0.2em;
text-shadow: 0 1px 0 #fff; text-shadow: 0 1px 0 #fff;
} }
#wiki-footer #footer-content p { #wiki-footer #footer-content p {
margin: 0.5em 0 0; margin: 0.5em 0 0;
padding: 0; padding: 0;
} }
#wiki-footer #footer-content ul.links { #wiki-footer #footer-content ul.links {
margin: 0.5em 0 0; margin: 0.5em 0 0;
overflow: hidden; overflow: hidden;
padding: 0; padding: 0;
} }
#wiki-footer #footer-content ul.links li { #wiki-footer #footer-content ul.links li {
color: #999; color: #999;
float: left; float: left;
@ -180,21 +180,21 @@
padding: 0; padding: 0;
margin-left: 0.75em; margin-left: 0.75em;
} }
#wiki-footer #footer-content ul.links li a { #wiki-footer #footer-content ul.links li a {
font-weight: bold; font-weight: bold;
text-shadow: 0 1px 0 #fff; text-shadow: 0 1px 0 #fff;
} }
#wiki-footer #footer-content ul.links li:first-child { #wiki-footer #footer-content ul.links li:first-child {
list-style-type: none; list-style-type: none;
margin: 0; margin: 0;
} }
.ff #wiki-footer #footer-content ul.links li:first-child { .ff #wiki-footer #footer-content ul.links li:first-child {
margin: 0 -0.75em 0 0; margin: 0 -0.75em 0 0;
} }
/* @section page-footer */ /* @section page-footer */
.page #gollum-footer { .page #gollum-footer {
border-top: 1px solid #ccc; border-top: 1px solid #ccc;
@ -221,23 +221,23 @@
margin: 2em 0; margin: 2em 0;
padding: 0; padding: 0;
} }
#wiki-history table, #wiki-history tbody { #wiki-history table, #wiki-history tbody {
border-collapse: collapse; border-collapse: collapse;
padding: 0; padding: 0;
margin: 0; margin: 0;
width: 100%; width: 100%;
} }
#wiki-history table tr { #wiki-history table tr {
padding: 0; padding: 0;
margin: 0; margin: 0;
} }
#wiki-history table tr { #wiki-history table tr {
background-color: #ebf2f6; background-color: #ebf2f6;
} }
#wiki-history table tr td { #wiki-history table tr td {
border: 1px solid #c0dce9; border: 1px solid #c0dce9;
font-size: 1.2em; font-size: 1.2em;
@ -245,13 +245,13 @@
margin: 0; margin: 0;
padding: 0.3em 0.7em; padding: 0.3em 0.7em;
} }
#wiki-history table tr td.checkbox { #wiki-history table tr td.checkbox {
min-width: 2em; min-width: 2em;
padding: 0.3em; padding: 0.3em;
width: 24px; width: 24px;
} }
#wiki-history table tr td.checkbox input { #wiki-history table tr td.checkbox input {
cursor: pointer; cursor: pointer;
display: block; display: block;
@ -259,39 +259,39 @@
padding-top: 0.4em; padding-top: 0.4em;
margin-right: -0.2em; margin-right: -0.2em;
} }
#wiki-history table tr:nth-child(2n), #wiki-history table tr:nth-child(2n),
#wiki-history table tr.alt-row { #wiki-history table tr.alt-row {
background-color: #f3f7fa; background-color: #f3f7fa;
} }
#wiki-history table tr.selected { #wiki-history table tr.selected {
background-color: #ffffea !important; background-color: #ffffea !important;
z-index: 100; z-index: 100;
} }
#wiki-history table tr td.commit-name { #wiki-history table tr td.commit-name {
border-left: 0; border-left: 0;
} }
#wiki-history table tr td.commit-name span.time-elapsed { #wiki-history table tr td.commit-name span.time-elapsed {
color: #999; color: #999;
} }
#wiki-history table tr td.author { #wiki-history table tr td.author {
width: 20%; width: 20%;
} }
#wiki-history table tr td.author a { #wiki-history table tr td.author a {
color: #000; color: #000;
font-weight: bold; font-weight: bold;
} }
#wiki-history table tr td.author a span.username { #wiki-history table tr td.author a span.username {
display: block; display: block;
padding-top: 3px; padding-top: 3px;
} }
#wiki-history table tr td img { #wiki-history table tr td img {
background-color: #fff; background-color: #fff;
border: 1px solid #999; border: 1px solid #999;
@ -303,7 +303,7 @@
width: 18px; width: 18px;
padding: 2px; padding: 2px;
} }
#wiki-history table tr td.commit-name a { #wiki-history table tr td.commit-name a {
font-size: 0.9em; font-size: 0.9em;
font-family: 'Monaco', 'Andale Mono', Consolas, 'Courier New', monospace; font-family: 'Monaco', 'Andale Mono', Consolas, 'Courier New', monospace;
@ -338,26 +338,26 @@
color: #000; color: #000;
font-weight: bold; font-weight: bold;
} }
.results #results { .results #results {
border-bottom: 1px solid #ccc; border-bottom: 1px solid #ccc;
margin-bottom: 2em; margin-bottom: 2em;
padding-bottom: 2em; padding-bottom: 2em;
} }
.results #results ul { .results #results ul {
margin: 2em 0 0 0; margin: 2em 0 0 0;
padding: 0; padding: 0;
padding-left: 25px; padding-left: 25px;
} }
.results #results ul li { .results #results ul li {
font-size: 1.2em; font-size: 1.2em;
line-height: 1.6em; line-height: 1.6em;
list-style-position: outside; list-style-position: outside;
padding: 0.2em 0; padding: 0.2em 0;
} }
.results #results ul li span.count { .results #results ul li span.count {
color: #999; color: #999;
} }
@ -367,11 +367,11 @@
line-height: 1.6em; line-height: 1.6em;
margin-top: 2em; margin-top: 2em;
} }
.results #footer ul.actions li { .results #footer ul.actions li {
margin: 0 1em 0 0; margin: 0 1em 0 0;
} }
/* @section compare */ /* @section compare */
.compare h1 { .compare h1 {
@ -383,11 +383,11 @@
color: #000; color: #000;
font-weight: bold; font-weight: bold;
} }
.compare #compare-content { .compare #compare-content {
margin-top: 3em; margin-top: 3em;
} }
.compare .data { .compare .data {
border: 1px solid #ddd; border: 1px solid #ddd;
margin-top: 1em; margin-top: 1em;
@ -398,16 +398,16 @@
.compare .data table { .compare .data table {
width: 100%; width: 100%;
} }
.compare .data pre { .compare .data pre {
margin: 0; margin: 0;
padding: 0; padding: 0;
} }
.compare .data pre div { .compare .data pre div {
padding: 0 0 0 1em; padding: 0 0 0 1em;
} }
.compare .data tr td { .compare .data tr td {
font-family: "Consolas", "Monaco", "Andale Mono", "Courier New", monospace; font-family: "Consolas", "Monaco", "Andale Mono", "Courier New", monospace;
font-size: 1.2em; font-size: 1.2em;
@ -415,11 +415,11 @@
margin: 0; margin: 0;
padding: 0; padding: 0;
} }
.compare .data td.line_numbers { .compare .data td.line_numbers {
background: #f7f7f7; background: #f7f7f7;
border-right: 1px solid #999; border-right: 1px solid #999;
color: #999; color: #999;
padding: 0 0 0 0.5em; padding: 0 0 0 0.5em;
width: 1%; width: 1%;
} }
@ -433,7 +433,7 @@
margin-left: 0; margin-left: 0;
margin-right: 0.6em; margin-right: 0.6em;
} }
/* git_access */ /* git_access */
//#wiki-content .url-box { //#wiki-content .url-box {
@ -450,7 +450,7 @@
// padding: 10px 10px 0; // padding: 10px 10px 0;
// width: 100%; // width: 100%;
//} //}
// //
//#wiki-content .url-box ul.clone_urls { //#wiki-content .url-box ul.clone_urls {
// float: left; // float: left;
// height: 23px; // height: 23px;
@ -539,30 +539,30 @@ ul.clone-urls li {
// padding: 3px 5px 2px; // padding: 3px 5px 2px;
// width: 400px; // width: 400px;
//} //}
/* @control syntax */ /* @control syntax */
.highlight { background: #ffffff; } .highlight { background: #ffffff; }
.highlight .c { color: #999988; font-style: italic } .highlight .c { color: #a50; font-style: italic; font-weight: bold; }
.highlight .err { color: #a61717; background-color: #e3d2d2 } .highlight .err { color: #a61717; background-color: #e3d2d2 }
.highlight .k { font-weight: bold } .highlight .k { font-weight: bold }
.highlight .o { font-weight: bold } .highlight .o { font-weight: bold }
.highlight .cm { color: #999988; font-style: italic } .highlight .cm { color: #999988; font-style: italic }
.highlight .cp { color: #999999; font-weight: bold } .highlight .cp { color: #999999; font-weight: bold }
.highlight .c1 { color: #999988; font-style: italic } .highlight .c1 { color: #999988; font-style: italic }
.highlight .cs { color: #999999; font-weight: bold; font-style: italic } .highlight .cs { color: #999999; font-weight: bold; font-style: italic }
.highlight .gd { color: #000000; background-color: #ffdddd } .highlight .gd { color: #000000; background-color: #ffdddd }
.highlight .gd .x { color: #000000; background-color: #ffaaaa } .highlight .gd .x { color: #000000; background-color: #ffaaaa }
.highlight .ge { font-style: italic } .highlight .ge { font-style: italic }
.highlight .gr { color: #aa0000 } .highlight .gr { color: #aa0000 }
.highlight .gh { color: #999999 } .highlight .gh { color: #b26818; font-weight: bold; }
.highlight .gi { color: #000000; background-color: #ddffdd } .highlight .gi { color: #000000; background-color: #ddffdd }
.highlight .gi .x { color: #000000; background-color: #aaffaa } .highlight .gi .x { color: #000000; background-color: #aaffaa }
.highlight .gc { color: #999; background-color: #EAF2F5 } .highlight .gc { color: #999; background-color: #EAF2F5 }
.highlight .go { color: #888888 } .highlight .go { color: #888888 }
.highlight .gp { color: #555555 } .highlight .gp { color: #555555 }
.highlight .gs { font-weight: bold } .highlight .gs { font-weight: bold }
.highlight .gu { color: #aaaaaa } .highlight .gu { color: #aaaaaa }
.highlight .gt { color: #aa0000 } .highlight .gt { color: #aa0000 }
/* @control minibutton */ /* @control minibutton */
@ -656,7 +656,7 @@ ul.actions {
margin: -10% 0 0 -35%; margin: -10% 0 0 -35%;
position: absolute; position: absolute;
width: 70%; width: 70%;
border-radius: 0.5em; border-radius: 0.5em;
-moz-border-radius: 0.5em; -moz-border-radius: 0.5em;
-webkit-border-radius: 0.5em; -webkit-border-radius: 0.5em;
@ -689,7 +689,7 @@ ul.actions {
background: #fff; background: #fff;
border: 1px solid #d4d4d4; border: 1px solid #d4d4d4;
overflow: hidden; overflow: hidden;
border-radius: 0.3em; border-radius: 0.3em;
-moz-border-radius: 0.3em; -moz-border-radius: 0.3em;
-webkit-border-radius: 0.3em; -webkit-border-radius: 0.3em;
@ -702,22 +702,22 @@ ul.actions {
font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
font-size: 1.2em; font-size: 1.2em;
height: 1.8em; height: 1.8em;
-webkit-focus-ring: none; -webkit-focus-ring: none;
} }
.ff #head #gollum-searchbar #gollum-searchbar-fauxtext input#search-query { .ff #head #gollum-searchbar #gollum-searchbar-fauxtext input#search-query {
padding: 0.2em 0 0.2em 0.5em; padding: 0.2em 0 0.2em 0.5em;
} }
.ie #head #gollum-searchbar #gollum-searchbar-fauxtext input#search-query { .ie #head #gollum-searchbar #gollum-searchbar-fauxtext input#search-query {
padding: 0.4em 0 0 0.5em; padding: 0.4em 0 0 0.5em;
} }
#head #gollum-searchbar #gollum-searchbar-fauxtext input#search-query.ph { #head #gollum-searchbar #gollum-searchbar-fauxtext input#search-query.ph {
color: #999; color: #999;
} }
#head #gollum-searchbar #gollum-searchbar-fauxtext #search-submit { #head #gollum-searchbar #gollum-searchbar-fauxtext #search-submit {
border: 0; border: 0;
border-left: 1px solid #d4d4d4; border-left: 1px solid #d4d4d4;
@ -726,12 +726,12 @@ ul.actions {
padding: 0; padding: 0;
float: right; float: right;
font-size: 1.2em; font-size: 1.2em;
border-radius: 0 3px 3px 0; border-radius: 0 3px 3px 0;
-moz-border-radius: 0 3px 3px 0; -moz-border-radius: 0 3px 3px 0;
-webkit-border-radius: 0 3px 3px 0; -webkit-border-radius: 0 3px 3px 0;
} }
#head #gollum-searchbar #gollum-searchbar-fauxtext #search-submit span { #head #gollum-searchbar #gollum-searchbar-fauxtext #search-submit span {
background-image: image-url('gollum/icon-sprite.png'); background-image: image-url('gollum/icon-sprite.png');
background-position: -431px -1px; background-position: -431px -1px;
@ -742,12 +742,12 @@ ul.actions {
text-indent: -5000px; text-indent: -5000px;
width: 28px; width: 28px;
} }
.ff #head #gollum-searchbar #gollum-searchbar-fauxtext #search-submit span, .ff #head #gollum-searchbar #gollum-searchbar-fauxtext #search-submit span,
.ie #head #gollum-searchbar #gollum-searchbar-fauxtext #search-submit span { .ie #head #gollum-searchbar #gollum-searchbar-fauxtext #search-submit span {
height: 2.2em; height: 2.2em;
} }
#head #gollum-searchbar #gollum-searchbar-fauxtext #search-submit:hover span { #head #gollum-searchbar #gollum-searchbar-fauxtext #search-submit:hover span {
background-position: -431px -28px; background-position: -431px -28px;
padding: 0; padding: 0;

View File

@ -48,7 +48,7 @@
.gs { font-weight: bold } /* Generic.Strong */ .gs { font-weight: bold } /* Generic.Strong */
.gu { color: #aaaaaa } /* Generic.Subheading */ .gu { color: #aaaaaa } /* Generic.Subheading */
.gt { color: #aa0000 } /* Generic.Traceback */ .gt { color: #aa0000 } /* Generic.Traceback */
.kc { color: #000000; font-weight: bold } /* Keyword.Constant */ .kc { color: #b218b2; font-weight: bold } /* Keyword.Constant */
.kd { color: #000000; font-weight: bold } /* Keyword.Declaration */ .kd { color: #000000; font-weight: bold } /* Keyword.Declaration */
.kn { color: #000000; font-weight: bold } /* Keyword.Namespace */ .kn { color: #000000; font-weight: bold } /* Keyword.Namespace */
.kp { color: #000000; font-weight: bold } /* Keyword.Pseudo */ .kp { color: #000000; font-weight: bold } /* Keyword.Pseudo */
@ -60,7 +60,7 @@
.nb { color: #0086B3 } /* Name.Builtin */ .nb { color: #0086B3 } /* Name.Builtin */
.nc { color: #445588; font-weight: bold } /* Name.Class */ .nc { color: #445588; font-weight: bold } /* Name.Class */
.no { color: #008080 } /* Name.Constant */ .no { color: #008080 } /* Name.Constant */
.nd { color: #3c5d5d; font-weight: bold } /* Name.Decorator */ .nd { color: green; font-weight: bold; } /* Name.Decorator */
.ni { color: #800080 } /* Name.Entity */ .ni { color: #800080 } /* Name.Entity */
.ne { color: #990000; font-weight: bold } /* Name.Exception */ .ne { color: #990000; font-weight: bold } /* Name.Exception */
.nf { color: #990000; font-weight: bold } /* Name.Function */ .nf { color: #990000; font-weight: bold } /* Name.Function */
@ -90,3 +90,5 @@
.vg { color: #008080 } /* Name.Variable.Global */ .vg { color: #008080 } /* Name.Variable.Global */
.vi { color: #008080 } /* Name.Variable.Instance */ .vi { color: #008080 } /* Name.Variable.Instance */
.il { color: #009999 } /* Literal.Number.Integer.Long */ .il { color: #009999 } /* Literal.Number.Integer.Long */
.c { color: #a50; } /* Comment */