diff --git a/source/less/_article.less b/source/less/_article.less index b214cd9..adf86ce 100755 --- a/source/less/_article.less +++ b/source/less/_article.less @@ -167,25 +167,25 @@ margin: 1em 0; padding: @gap; border-left: @border_radius_left_line solid @theme_bg_quote; - // border-radius: @border_radius_code_block; .enable-trans(); - // &:hover{ - // border-left: @border_radius solid @theme_bg_quote; - // border-radius: @border_radius; - // } footer { strong { margin-right: 7px; } } - + &.right{ + p{ + text-align: right; + } + } } + pre { display: block; -moz-box-sizing: border-box; box-sizing: border-box; font-family: @fontfamily_code; - color: fade(@theme_text_main, 90%); + color: @theme_text_main; } code { font-family: @fontfamily_code; @@ -343,43 +343,9 @@ } } -/* Tomorrow Night Eighties Theme */ -/* Original theme - https://github.com/chriskempson/tomorrow-theme */ -/* http://jmblog.github.com/color-themes-for-google-code-highlightjs */ -.tomorrow-comment, pre .comment, pre .title { - color: #999999; -} - -.tomorrow-red, pre .variable, pre .attribute, pre .tag, pre .regexp, pre .ruby .constant, pre .xml .tag .title, pre .xml .pi, pre .xml .doctype, pre .html .doctype, pre .css .id, pre .css .class, pre .css .pseudo { - color: #f2777a; -} - -.tomorrow-orange, pre .number, pre .preprocessor, pre .built_in, pre .literal, pre .params, pre .constant { - color: #f99157; -} - -.tomorrow-yellow, pre .class, pre .ruby .class .title, pre .css .rules .attribute { - color: #ffcc66; -} - -.tomorrow-green, pre .string, pre .value, pre .inheritance, pre .header, pre .ruby .symbol, pre .xml .cdata { - color: #99cc99; -} - -.tomorrow-aqua, pre .css .hexcolor { - color: #66cccc; -} - -.tomorrow-blue, pre .function, pre .python .decorator, pre .python .title, pre .ruby .function .title, pre .ruby .title .keyword, pre .perl .sub, pre .javascript .title, pre .coffeescript .title { - color: #6699cc; -} - -.tomorrow-purple, pre .keyword, pre .javascript .function { - color: #cc99cc; -} .highlight { - position: relative; + position: relative; width: 100%; margin-top: 1em; margin-bottom: 1.2em; @@ -391,6 +357,10 @@ line-height: @lineheight_base; border-radius: @border_radius_code_block; .enable-trans(); + figcaption{ + padding: @gap/4 @gap/2; + background-color: darken(@theme_bg_code_block, 3%); + } table{ td,th{ padding: 0; @@ -419,7 +389,7 @@ position: absolute; top: 0; right: 0; - color: fade(@theme_text_main, 40%); + color: fade(@theme_text_main, 60%); font-size: @fontsize_footnote; padding: 4px 8px 0; line-height: @lineheight_base; @@ -520,3 +490,57 @@ font-size: @fontsize_small * .95 * .95; } } + +@hl_keyword: #9c27b0; +@hl_blue: #1E80F0; +@hl_cyan: #17AFCA; +@hl_green: #3FA33F; +@hl_light_blue: #6ECDF9; +@hl_red: #EE2B29; +@hl_orange: #FB3F1B; +@hl_amber: #FD8607; + +pre{ + // 行 + .line{ + } + .marked{ + background-color: fade(@color_mac_minimize, 20%); + border-radius: 2px; + border: 1px solid fade(@color_mac_minimize, 40%); + } + // 注释 + .comment, .title{ + color: fade(@theme_text_main, 50%); + } + .keyword, .javascript .function, .tag { + color: @hl_keyword; + } + .type, .built_in{ + color: @hl_blue; + } + .variable, .attribute, .regexp, .ruby .constant, .xml .tag .title, .xml .pi, .xml .doctype, .html .doctype, .css .id, .css .class, .css .pseudo { + color: @hl_amber; + } + .number, .preprocessor, .literal, .params, .constant { + color: @hl_amber; + } + .class, .ruby .class .title, .css .rules .attribute { + color: #ffcc66; + } + .string, .value, .inheritance, .header, .ruby .symbol, .xml .cdata { + color: @color_md_green; + } + .css .hexcolor { + color: #66cccc; + } + .function, .python .decorator, .python .title, .ruby .function .title, .ruby .title .keyword, .perl .sub, .javascript .title, .coffeescript .title { + color: #6699cc; + } + +} +.json{ + .attr{ + color: @hl_keyword; + } +} diff --git a/source/less/_base.less b/source/less/_base.less index c6dbbbb..ec65339 100755 --- a/source/less/_base.less +++ b/source/less/_base.less @@ -38,7 +38,7 @@ body { } &.z_menu-open { .menu-phone { - transform: translate3d(-10px, 0, 0); + transform: translate3d(-@gap, 0, 0); } } } diff --git a/source/less/_header.less b/source/less/_header.less index 4fdb4fe..71d5197 100755 --- a/source/less/_header.less +++ b/source/less/_header.less @@ -93,16 +93,17 @@ height: @height_navbar - @gap; .enable-trans(); margin: 0; + @height: @height_navbar - 1.2*@gap; @media(max-width: @on_phone){ - width: @height_navbar - 1.5*@gap; - height: @height_navbar - 1.5*@gap; + width: @height; + height: @height; } a{ display: flex; justify-content: center; align-items: center; - width: @height_navbar - @gap; - height: @height_navbar - @gap; + width: @height; + height: @height; border-radius: 100px; .enable-trans(); &:hover { @@ -110,15 +111,15 @@ // color: @theme_bg_quote; } @media(max-width: @on_phone){ - width: @height_navbar - 1.5*@gap; - height: @height_navbar - 1.5*@gap; + width: @height; + height: @height; } } } @media(max-width: @on_phone){ display: flex; padding-left: @gap/2; - padding-right: @gap; + padding-right: @gap - 6px; } } .nav-sub .switcher{