.slideUp()

.slideUp( [duration ] [, complete ] )Returns: jQuery

Description: Hide the matched elements with a sliding motion.

  • version added: 1.0.slideUp( [duration ] [, complete ] )

    • duration (default: 400)
      Type: Number or String
      A string or number determining how long the animation will run.
    • complete
      Type: Function()
      A function to call once the animation is complete, called once per matched element.
  • version added: 1.0.slideUp( options )

    • options
      A map of additional options to pass to the method.
      • duration (default: 400)
        Type: Number or String
        A string or number determining how long the animation will run.
      • easing (default: swing)
        Type: String
        A string indicating which easing function to use for the transition.
      • queue (default: true)
        Type: Boolean or String
        A Boolean indicating whether to place the animation in the effects queue. If false, the animation will begin immediately. As of jQuery 1.7, the queue option can also accept a string, in which case the animation is added to the queue represented by that string. When a custom queue name is used the animation does not automatically start; you must call .dequeue("queuename") to start it.
      • specialEasing
        An object containing one or more of the CSS properties defined by the properties argument and their corresponding easing functions. (version added: 1.4)
      • step
        Type: Function( Number now, Tween tween )
        A function to be called for each animated property of each animated element. This function provides an opportunity to modify the Tween object to change the value of the property before it is set.
      • progress
        Type: Function( Promise animation, Number progress, Number remainingMs )
        A function to be called after each step of the animation, only once per animated element regardless of the number of animated properties. (version added: 1.8)
      • complete
        Type: Function()
        A function that is called once the animation on an element is complete.
      • start
        Type: Function( Promise animation )
        A function to call when the animation on an element begins. (version added: 1.8)
      • done
        Type: Function( Promise animation, Boolean jumpedToEnd )
        A function to be called when the animation on an element completes (its Promise object is resolved). (version added: 1.8)
      • fail
        Type: Function( Promise animation, Boolean jumpedToEnd )
        A function to be called when the animation on an element fails to complete (its Promise object is rejected). (version added: 1.8)
      • always
        Type: Function( Promise animation, Boolean jumpedToEnd )
        A function to be called when the animation on an element completes or stops without completing (its Promise object is either resolved or rejected). (version added: 1.8)
  • version added: 1.4.3.slideUp( [duration ] [, easing ] [, complete ] )

    • duration (default: 400)
      Type: Number or String
      A string or number determining how long the animation will run.
    • easing (default: swing)
      Type: String
      A string indicating which easing function to use for the transition.
    • complete
      Type: Function()
      A function to call once the animation is complete, called once per matched element.

The .slideUp() method animates the height of the matched elements. This causes lower parts of the page to slide up, appearing to conceal the items. Once the height reaches 0 (or, if set, to whatever the CSS min-height property is), the display style property is set to none to ensure that the element no longer affects the layout of the page.

Durations are given in milliseconds; higher values indicate slower animations, not faster ones. The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 milliseconds, respectively. If any other string is supplied, or if the duration parameter is omitted, the default duration of 400 milliseconds is used.

.slideUp()的更多相关文章

  1. jQuery动画slideUp()不正常位移原因

    用jQuery写一个列表.当点击底部按钮时,列表中序号超过6的项目可以向下拉出或者向上收起. 用slideUp(),遇见一个问题.展开列表项会产生不正常位移,如下图所示.动画结束发生位移. 出现这个问 ...

  2. 今天是JQ 的slideUp 和 slideDown 的点击事件

    先贴代码,再讲详细事件 <!DOCTYPE html> <html> <head> <meta charset="utf-8"> & ...

  3. jq slideUp slideDown

    <!DOCTYPE html> <html> <head lang="en"> <meta charset="UTF-8&quo ...

  4. 工作日志 jquery slideDown slideUp

    jquery里面使用 slideDown 和  slideUp会有一个像素的偏差

  5. jquery 连写注释;siblings() 方法;jQuery 的3种滑动方法;slideUp()向上滑动;slideDown()向下滑动;slideToggle()来回滑动

    首先我们看两个连写注释 第一个:   /* 点击头像,显示基本资料 */ $(".f-chatTit a.avatar").click(function(){ $(this).hi ...

  6. js冒泡事件的特例toggle无法实现阻止冒泡——slideDown()和slideUp()

    一.问题 题目及答案展示:要求,点击题目,展开答案.如下: 展开前 展开后 最开始使用的toggle方法来实现 $(".content_problem").toggle( func ...

  7. jquery slideDown slideUp 对于table无效

    jquery slideDown slideUp 对于table无效,需要在table外面套一层div才可以使用

  8. 关于slideup和slidedown 鼠标多次滑过累积的动画效果

    stop() 方法停止当前正在运行的动画 包括animation动画和slideup/slidedown动画 例如:鼠标经过一个元素时,执行一个slide动画,多次快速经过,不处理的话这个元素会保留累 ...

  9. jquery的slideUp、slideDown、slideToggle等涉及滑动效果的一系列函数,在IE浏览器下有几处bug

    jquery的slideUp.slideDown.slideToggle等涉及滑动效果的一系列函数,在IE浏览器下有几处bug: 1. 因position引起的问题 影响:IE全系列 症状:在需要sl ...

  10. slideToggle+slideup实现手机端折叠菜单效果

    折叠菜单的效果,网上有很多的插件,比如bootstrap的 Collapse ,很好用也很简单,但是如果你使用的不是bootstrap框架,就会造成很多不必要的麻烦,比如默认样式被修改,代码冗余等等, ...

随机推荐

  1. 计算机网络:这是一份全面 & 详细 的TCP协议学习指南

    原文链接:blog.csdn.net 用这个媒体播放器组件,实时互动时也可共同观看本地视频juejin.im 前言 计算机网络基础 该是程序猿需掌握的知识,但往往会被忽略 今天,我将详细讲解计算机网络 ...

  2. git解决pre-commit hook failed的问题

    最近在提交前端代码的时候发现提交不上去,一直报错 一.错误详情 二.错误分析 1.刚开始用vsCode提交,后更改为命令提交,依旧报错: 2.经过查询资料,发现是pre-commit钩子的原因.   ...

  3. webpack4 打包

    1. 基本安装及命令 npm config set registry https://registry.npm.taobao.org     //  淘宝镜像npm install webpack-c ...

  4. elastic 查询

    1.match 查询 GET /_index/_search { "query": { "match": { " } } } 1.match 多条件查 ...

  5. Ubuntu中用sudo apt-get install makeinfo时,出错:Unable to locate package

    背景: 在准备ARM交叉编译环境时,执行命令: DISTRO=fsl-imx-x11 MACHINE=imx6qsabresd source fsl-setup-release.sh -b build ...

  6. VirtualBox给CentOS虚拟机挂载磁盘扩大空间

    VirtualBox给CentOS虚拟机挂载磁盘扩大空间 楼主,发现虚拟机使用存储空间不够用的情况,需要改虚拟机挂载磁盘,扩容,在网上找了一波资料,于是整合记录操详细作如下: 概要步骤如下: 1.设置 ...

  7. Java语言基础(6)

    1 while循环 案例:Demo1 1+2+3+4+5+...+100 = ? 首先定义一个变量sum,用来保存累加之和,int sum=0 第1次:sum = sum + 1 第2次: sum = ...

  8. 标准C语言(9)

    C语言里所有文字信息必须记录在一组连续的字符类型存储区里所有文字信息必须以字符'\0'做结尾,这个字符的ASCII码就是0符合以上两个特征的内容叫字符串,它们可以用来在程序里记录文字信息.字符串里'\ ...

  9. 同步windows时间到linux服务器

    输入date -R 查看系统时间 输入命令  ntpdate time.windows.com 同步windows时间到linux

  10. redis事务(转载)

    原文地址:http://blog.csdn.net/hechurui/article/details/49508749 Redis事务 首先,Redis本身是单线程的. redis中的事务(trans ...