• js中级第12天


    1.动画

           (1)css样式提供了运动

              过渡的属性transition从一种情况到另种情况叫过渡

              transition:attr    time    linear    delay;

             attr是变化的属性

             time是花费的时间

             linear变化的速度

            delay是延迟

    复习background:url() no-repeat   50%    50%   red;

           background-image

           background-repeat

           background-position

           background-color

                  (2)

          元素的client  offset   scroll三个系列

    clientWidth/clientHeight/clientTop/clientLeft

    offsetWidth/offsetHeight/offsetLeftTop/offsetParent

    scrollWidth/offsetHeight/scrollTop/scrollLeft

    这是三个属性,前面是一个只读属性,scrollTop和scrollLeft是即可读也可写

    获取浏览器的body属性是有兼容的

    var dd=document.body||document.documentElement

    scrollTop和scrollLeft的最小值是0

    获取body的整个文档的高

    document.body.scrollHeight||document.documentElement.scrollHeight

    获取浏览器屏幕的宽(浏览器的可视区)

    document.body.clientHeight||document.documentElement.clientHeight

    window下的两个时间

          onscroll当滚动条的时候触发

          onresize当窗口发生改变时触发

  • 相关阅读:
    CF 526F Max Mex(倍增求LCA+线段树路径合并)
    CoderForces Round526 (A~E)题解
    牛客OI周赛4-提高组 A K小生成树(kmst)
    Codeforces 1072 C
    Codeforces 1053 C
    牛客国庆集训派对Day3 B Tree
    牛客国庆集训派对Day3 I Metropolis
    牛客国庆集训派对Day3 A Knight
    牛客国庆集训派对Day3 G Stones
    Codeforces 1053 B
  • 原文地址:https://www.cnblogs.com/jiangningjn/p/10038576.html
Copyright © 2020-2023  润新知