bob体育官方平台
jquery完结手风琴效果_jquery_脚本之家

bob体育官方平台,本文实例讲述了jquery实现手风琴效果的代码。分享给大家供大家参考。具体如下:

一款基于jquery的手风琴图片展示效果,jquery手风琴

今天要给大家分享一款基于jquery的手风琴图片展示效果。这款图片的展示效果鼠标经过前是灰色的,当鼠标经过时图片变大且变为彩色。效果图如下:

bob体育app 1

bob体育app,在线预览   源码下载

实现的代码。

html代码:

 <div class="page-container">
        <div class="flex-container">
            <div class="country netherlands">
                <div>
                    Netherlands</div>
            </div>
            <div class="country belgium">
                <div>
                    Belgium</div>
            </div>
            <div class="country france">
                <div>
                    France</div>
            </div>
            <div class="country germany">
                <div>
                    Germany</div>
            </div>
            <div class="country england">
                <div>
                    England</div>
            </div>
        </div>
    </div>
    <script src='jquery.js'></script>
    <script>
        $('.country').click(function () {
            $(this).toggleClass('active');
            $('.page-container').toggleClass('opened');
        }); //@ sourceURL=pen.js
    </script>

css代码:

  div
        {
            -moz-box-sizing: border-box;
            box-sizing: border-box;
        }

        html, body, .page-container
        {
            height: 100%;
            overflow: hidden;
        }

        .page-container
        {
            -webkit-transition: padding 0.2s ease-in;
            transition: padding 0.2s ease-in;
            padding: 80px;
        }
        .page-container.opened
        {
            padding: 0;
        }
        .page-container.opened .flex-container .country:not(.active)
        {
            opacity: 0;
            -webkit-flex: 0;
            -ms-flex: 0;
            flex: 0;
        }
        .page-container.opened .flex-container .country:not(.active) div
        {
            opacity: 0;
        }
        .page-container.opened .flex-container .active:after
        {
            -webkit-filter: grayscale(0%) !important;
            filter: grayscale(0%) !important;
        }

        .flex-container
        {
            display: -webkit-flex;
            display: -ms-flexbox;
            display: flex;
            height: 100%;
        }
        @media all and (max-width: 900px)
        {
            .flex-container
            {
                -webkit-flex-direction: column;
                -ms-flex-direction: column;
                flex-direction: column;
            }
        }

        .country
        {
            position: relative;
            -webkit-flex-grow: 1;
            -ms-flex-positive: 1;
            flex-grow: 1;
            -webkit-flex: 1;
            -ms-flex: 1;
            flex: 1;
            -webkit-transition: 0.5s ease-in-out;
            transition: 0.5s ease-in-out;
            cursor: pointer;
            font-family: "Bree Serif" , serif;
            text-align: center;
            color: #fff;
            font-size: 22px;
            text-shadow: 0 0 3px #000;
        }
        .country div
        {
            position: absolute;
            width: 100%;
            z-index: 10;
            top: 50%;
            text-align: center;
            -webkit-transition: 0.1s;
            transition: 0.1s;
            -webkit-transform: translateY(-50%);
            -ms-transform: translateY(-50%);
            transform: translateY(-50%);
            -webkit-filter: none;
            filter: none;
        }
        .country:after
        {
            content: " ";
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background-size: cover;
            -webkit-transition: 0.5s ease-in-out;
            transition: 0.5s ease-in-out;
            -webkit-filter: grayscale(100%);
            filter: grayscale(100%);
        }
        .country:hover
        {
            -webkit-flex-grow: 6;
            -ms-flex-positive: 6;
            flex-grow: 6;
        }
        .country:hover:after
        {
            -webkit-filter: grayscale(0%);
            filter: grayscale(0%);
        }
        @media all and (max-width: 900px)
        {
            .country
            {
                height: auto;
            }
        }

        .netherlands:after
        {
            background-image: url("Netherlands.png");
            background-position: center;
        }

        .belgium:after
        {
            background-image: url("belgium-307_3.jpg");
            background-position: center;
        }

        .france:after
        {
            background-image: url("30.jpg");
            background-position: center;
        }

        .germany:after
        {
            background-image: url("vacation.jpg");
            background-position: center;
        }

        .england:after
        {
            background-image: url("england.jpg");
            background-position: center;
        }

注:本文爱编程原创文章,转载请注明原文地址:

效果过程就是当鼠标覆盖图片时,这张图片的宽度变大,其他兄弟图片宽度变小,效果如下:

jQuery手风琴菜单 跪图面上面这种JQ手风琴效果,带排行的

唉。。。。。。。怎么都是找插件的人呢。  

jQuery横向手风琴图片展示动画DEMO演示给你15分钟做“对”的时尚人服饰封面明星故事2015春夏趋势我爱海淘蒂芙尼为你吟唱一曲自然颂服饰封面明星故事2015春夏趋势我爱海淘瑞丽·妆线上精品轻杂志服饰封面明星故事2015春夏趋势我爱海淘《ar》刘海造型女孩只需这样即刻焕然一新服饰封面明星故事2015春夏趋势我爱海淘电影×大明星见证传奇从戛纳诞生服饰封面明星故事2015春夏趋势我爱海淘重返20岁试用周服饰封面明星故事2015春夏趋势我爱海淘玩美女孩盖天天阳光女神进阶攻略服饰封面明星故事2015春夏趋势我爱海淘

高分jquery 手风琴效果实现代码

$("#topBox li").toggle(function(){
$(this).find("ul").show();

},function(){
$(this).find("ul").hide();
});  

今天要给大家分享一款基于jquery的手风琴图片展示效果。这款图片的展示效果鼠标经过前...

CSS代码:

@charset"utf-8";*{margin:0px;padding:0px;font-family:"微软雅黑";font-size:12px; text-decoration:none;list-style-type:none;}img{border:0px;}/*开始*/.flash4{width:1180px;height:450px;margin:0pxauto;margin-bottom:20px;position:relative;}.flash4 ul li{width:106px;height:450px;border-left:1px solid #000;position:relative;overflow:hidden;float:left;}.flash4 ul li .imgTop img{opacity:0.4;}.flash4 ul li .imgTop img.tm{opacity:1;}.flash4 ul li .imgCon{width:538px;height:405px;}.flash4 ul li .imgCen{width:538px;height:50px;background:rgba;color:#fff;font-size:20px;line-height:50px;position:absolute;left:0px;bottom:45px;text-indent:20px;display:none;}.flash4 ul li .imgBot{width:538px;height:45px;background:#222;}.flash4 ul li .imgBot p.bt_1{width:80px;line-height:45px;font-size:16px;color:#fff;text-indent:20px;float:left;}.flash4 ul li .imgBot p.bt_2{width:458px;height:45px;line-height:45px;float:left;display:none;}.flash4 ul li .imgBot p.bt_2 span{font-size:14px;color:#fff;padding-right:30px;background:url(../images/part2_icon.png)no-repeat left center;padding-left:10px;}.flash4 ul li.first{width:538px;}.flash4 ul li.last{position:absolute;right:0px;bottom:0px;}
返回顶部