This commit is contained in:
@@ -19,7 +19,7 @@
|
||||
* @fileoverview util and every page should be used.
|
||||
*
|
||||
* @author <a href="http://vanessa.b3log.org">Liyuan Li</a>
|
||||
* @version 0.1.0.0, Dec 7, 2018
|
||||
* @version 0.2.0.0, Jan 30, 2019
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -27,6 +27,19 @@
|
||||
* @static
|
||||
*/
|
||||
var Skin = {
|
||||
initToc: function () {
|
||||
if ($('.b3-solo-list li').length > 0 && $(window).width() > 768) {
|
||||
$('.b3-solo-list').css({
|
||||
right: '50px',
|
||||
'border-right': '1px solid #fff',
|
||||
opacity: 1,
|
||||
})
|
||||
$('#pjax.wrapper').css({
|
||||
'max-width': '968px',
|
||||
'padding-right': '270px',
|
||||
})
|
||||
}
|
||||
},
|
||||
init: function () {
|
||||
Util.initPjax(function () {
|
||||
$('.header a').each(function () {
|
||||
@@ -36,6 +49,15 @@ var Skin = {
|
||||
this.className = 'tooltipped tooltipped__w'
|
||||
}
|
||||
})
|
||||
|
||||
if ($('.b3-solo-list li').length > 0 && $(window).width() > 768) {
|
||||
$('#pjax.wrapper').css({
|
||||
'max-width': '968px',
|
||||
'padding-right': '270px',
|
||||
})
|
||||
} else {
|
||||
$('#pjax.wrapper').removeAttr('style')
|
||||
}
|
||||
})
|
||||
|
||||
$('.header a').each(function () {
|
||||
|
2
Jane/js/common.min.js
vendored
2
Jane/js/common.min.js
vendored
@@ -15,4 +15,4 @@
|
||||
* You should have received a copy of the GNU Affero General Public License
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
var Skin={init:function(){Util.initPjax(function(){$(".header a").each(function(){this.href===location.href?this.className="current tooltipped tooltipped__w":this.className="tooltipped tooltipped__w"})}),$(".header a").each(function(){this.href===location.href&&(this.className="current tooltipped tooltipped__w")}).click(function(){$(".header a").removeClass("current"),this.className="current tooltipped tooltipped__w"}),$("body").on("click",".content-reset img",function(){window.open(this.src)})}};Skin.init();
|
||||
var Skin={initToc:function(){0<$(".b3-solo-list li").length&&768<$(window).width()&&($(".b3-solo-list").css({right:"50px","border-right":"1px solid #fff",opacity:1}),$("#pjax.wrapper").css({"max-width":"968px","padding-right":"270px"}))},init:function(){Util.initPjax(function(){$(".header a").each(function(){this.href===location.href?this.className="current tooltipped tooltipped__w":this.className="tooltipped tooltipped__w"}),0<$(".b3-solo-list li").length&&768<$(window).width()?$("#pjax.wrapper").css({"max-width":"968px","padding-right":"270px"}):$("#pjax.wrapper").removeAttr("style")}),$(".header a").each(function(){this.href===location.href&&(this.className="current tooltipped tooltipped__w")}).click(function(){$(".header a").removeClass("current"),this.className="current tooltipped tooltipped__w"}),$("body").on("click",".content-reset img",function(){window.open(this.src)})}};Skin.init();
|
Reference in New Issue
Block a user