zoukankan      html  css  js  c++  java
  • Chrome中 样式:after的问题

    今天在看一个CSS3进度条DEMO时发现在chrome中的某元素 :after 样式显示不正常,下面是DEMO的地址

    http://www.css88.com/demo/css3-progress-bars/

    第二个进度条在chrome浏览器中无动画效果,贴出样式:

    .shine span {
        position: relative;
    }
    
    .shine span::after {
        content: '';
        opacity: 0;
        position: absolute;
        top: 0;
        right: 0;
        bottom: 0;
        left: 0;
        background: #fff;
        -moz-border-radius: 3px;
        -webkit-border-radius: 3px;
        border-radius: 3px;            
        
                    /*动画*/
        -webkit-animation: animate-shine 2s ease-out infinite;
        -moz-animation: animate-shine 2s ease-out infinite;             
    }
    
    /*动画*/
    @-webkit-keyframes animate-shine { 
        0% {opacity: 0; width: 0;}
        50% {opacity: .5;}
        100% {opacity: 0; width: 95%;}
    }
    
    
    @-moz-keyframes animate-shine {
        0% {opacity: 0; width: 0;}
        50% {opacity: .5;}
        100% {opacity: 0; width: 95%;}
    }

    最后再内容后面多加了个<span></span>   把after的样式加到这个样式上   .shine span::after   改成  .shine span span  测试后运行无问题,但始终没有找到问题所在~

  • 相关阅读:
    HDU 5710 digit sum
    Fibonacci Tree HDU
    2016CCPC东北赛补题
    紫书水题
    20180415校赛
    随心所欲小游戏
    Alpha版本测试报告
    第四天作业
    第二天作业
    第一天作业
  • 原文地址:https://www.cnblogs.com/BiakeChou/p/2556122.html
Copyright © 2011-2022 走看看