Ver código fonte

导航栏可选透明

pull/16/head
Zisbusy 2 anos atrás
pai
commit
5d6f7d83d8
3 arquivos alterados com 40 adições e 7 exclusões
  1. +8
    -7
      Akina/functions.php
  2. +7
    -0
      Akina/post.php
  3. +25
    -0
      Akina/style.php

+ 8
- 7
Akina/functions.php Ver arquivo

@ -121,13 +121,14 @@ echo '

博客信息

';
$menu = new Typecho_Widget_Helper_Form_Element_Checkbox('menu',
array(
'show' => _t('一直显示菜单'),
'indexbg' => _t('一直显示首页大图'),
'feature' => _t('一直显示聚焦内容'),
'page' => _t('使用ajax加载文章'),
'xl' => _t('下拉自动加载文章'),
'dark' => _t('开启夜间模式(跟随系统)'),
),
'show' => _t('一直显示菜单'),
'transparent' => _t('导航栏透明'),
'indexbg' => _t('一直显示首页大图'),
'feature' => _t('一直显示聚焦内容'),
'page' => _t('使用ajax加载文章'),
'xl' => _t('下拉自动加载文章'),
'dark' => _t('开启夜间模式(跟随系统)'),
),
array('page'), _t('其他设置'));
$form->addInput($menu->multiMode());

+ 7
- 0
Akina/post.php Ver arquivo

@ -36,6 +36,13 @@
');
}
?>
<?php if ( $this->fields->radioPostImg != 'none' && $this->fields->radioPostImg != null && !empty($this->options->menu) && in_array('transparent', $this->options->menu) ): ?>
<style>
.site-main {
padding: 80px 0 0;
}
</style>
<?php endif ?>
<div id="content" class="site-content">
<?php
// 文章目录展示以及切换

+ 25
- 0
Akina/style.php Ver arquivo

@ -44,6 +44,31 @@
}
';
}
// 导航栏透明
if (!empty($this->options->menu) && in_array('transparent', $this->options->menu)) {
echo '
.site-header {
background: #fff0;
}
.headertop {
margin-top: 0px;
}
.focusinfo {
top: 47%;
}
@media (min-width: 860px) and (max-width: 1080px){
.notice {
margin-top: 150px;
}
}
.site-main {
padding: 160px 0 0;
}
#centerbg {
height: 630px;
}
';
}
?>
/* 到顶部按钮 */
.wedonate img {

Carregando…
Cancelar
Salvar