【转】handsome首页标题美化代码美化

转自神代綺凜の萌化小基地

首先下载

此处内容需要评论回复后(审核通过)方可阅读。

下载并替换
/usr/themes/handsome/libs/Content.php
然后在自定义CSS中加入下列代码:

@charset "utf-8";
/*
    CSS from 神代綺凜 - https://lolico.moe
    Modified by Yi - https://www.yeyi.site
*/

#widget-tabs-4-comments .list-group-item,#tag_toc,#post-panel,#sidebar,#post-content {
    background-color: transparent!important;
}

.blog-post>.panel,.blog-post>.panel-small {
    border: 0;
    border-radius: 5px;
}

.blog-post>.panel .index-post-img .item-thumb,.panel-small .index-post-img-small .item-thumb-small,.index-post-title a {
    transition: all .2s;
}

.blog-post>.panel:hover .index-post-img .item-thumb,.blog-post>.panel-small:hover .index-post-img-small .item-thumb-small {
    transform: scale(1.05);
}

.visible-xs-inline {
    display: inline-block!important;
}

@media screen and (min-width: 1200px) {
    .panel .item-thumb {
        height:300px;
    }

    #post-panel .blog-post {
        position: relative;
    }

    #post-panel .panel {
        overflow: hidden;
    }

    #post-panel .panel .post-meta {
        position: relative;
        margin-top: -300px;
        height: 300px;
        padding-top: 133px!important;
        padding-bottom: 0!important;
        background-color: rgba(0,0,0,.3);
        color: #fff!important;
        transition: all .3s;
    }

    #post-panel .panel .post-meta,#post-panel .panel-small .post-meta {
        border-radius: 5px;
    }

    #post-panel .panel .post-meta *,#post-panel .panel-small .post-meta * {
        color: #fff!important;
    }

    #post-panel .panel .post-meta>h2,#post-panel .panel-small .post-meta>h2 {
        text-align: center;
        text-shadow: 0 0 3px #fff;
    }

    #post-panel .panel .post-meta>p,#post-panel .panel .post-meta>div,#post-panel .panel-small .post-meta>p,#post-panel .panel-small .post-meta>div {
        transition: all .3s;
        transform: translateY(-10px);
        opacity: 0;
    }

    #post-panel .panel .post-meta>.text-muted,#post-panel .panel-small .post-meta>.text-muted {
        position: absolute;
        bottom: 20px;
    }

    #post-panel .panel .post-meta>.line {
        position: absolute;
        bottom: 40px;
    }

    #post-panel .panel-small .post-meta>.line {
        position: absolute;
        bottom: 40px;
    }

    #post-panel .panel .post-meta>.summary {
        margin: 32px auto;
        width: 510px;
    }

    #post-panel .panel-small .post-meta>.summary {
        margin: 32px auto;
        width: 240px;
    }

    #post-panel .panel-small {
        display: inline-block;
        height: 300px;
        width: calc(50% - 10px);
        margin-right: 20px;
    }

    #post-panel .panel-small+.panel-small {
        margin-right: 0;
    }

    #post-panel .panel-small .index-img-small,#post-panel .panel-small .index-img-small .item-thumb-small {
        height: 100%;
        width: 100%;
    }

    #post-panel .panel-small .post-meta {
        position: absolute;
        height: 300px;
        width: calc(50% - 10px);
        padding: 133px 20px 0 20px!important;
        background-color: rgba(0,0,0,.3);
        color: #fff!important;
        transition: all .3s;
    }

    #post-panel .panel:hover .post-meta,#post-panel .panel-small:hover .post-meta {
        background-color: rgba(0,0,0,.6);
    }

    #post-panel .panel:hover .post-meta>p,#post-panel .panel:hover .post-meta>div,#post-panel .panel-small:hover .post-meta>p,#post-panel .panel-small:hover .post-meta>div {
        opacity: 1;
        transform: translateY(0);
    }

    #post-panel .panel:hover .post-meta,#post-panel .panel-small:hover .post-meta {
        padding-top: 80px!important;
    }

    #post-panel .ahover {
        display: block;
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
    }

    .blog-post>.panel:hover .index-post-img,.blog-post>.panel-small:hover .index-post-img-small {
        filter: blur(3px);
    }
}

header.bg-light.wrapper-md {
    margin-top: 30px;
    background-color: transparent!important;
    border: 0;
    text-align: center;
    text-shadow: 0 0 3px #000;
}

header.wrapper-md * {
    color: #fff;
}

header.wrapper-md h1 {
    font-size: 32px;
}

header.wrapper-md h1 {
    font-weight: bold!important;
}

.sticky {
    position: absolute;
    top: 10px;
    left: 15px;
}
Last modification:December 4th, 2018 at 07:35 pm
If you think my article is useful to you, please feel free to appreciate

15 comments

  1. chen

    |´・ω・)ノ我冲着主题来的

    1. 颔首
      @chen

      指路友链友人C

  2. 撩人的无眠兔

    来这里学习下 留个脚印

    1. 颔首
  3. Hashaki

    我来看看

    1. 颔首
      @Hashaki

      w你的站进不去鸭

  4. 洛小依

    我也看看

    1. 颔首
      @洛小依

      ( ๑´•ω•) "(ㆆᴗㆆ)

  5. 夫君君风格

    查看

  6. Quanyin

    为了content.php...
    完全替换的方式不友好,应该告诉说要修改哪些内容,因为我的content.php被我自己改过,还得比对

    1. 颔首
      @Quanyin

      φ( ̄∇ ̄o)你可以去作者那里摸摸鱼也许有答案

      1. Quanyin
        @颔首

        看了下文件改动内容,不仅仅是文件首页头图改变,还改了其他的好多东西。。。只能慢慢调调了。。

        1. 颔首
          @Quanyin

          改完以后艾特我一下鸭我去捧场

          1. Quanyin
            @颔首

            实测,并不需要替换content.php....

            1. 颔首
              @Quanyin

              那可还行

Leave a Comment