• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

ksylvest/jquery-growl: Growler is a jQuery plugin designed to provide informativ ...

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称:

ksylvest/jquery-growl

开源软件地址:

https://github.com/ksylvest/jquery-growl

开源编程语言:

CSS 57.4%

开源软件介绍:

jQuery Growl

Growl is a jQuery plugin designed to provide informative messages in the browser.

Installation

To install copy the javascripts, and stylesheets directories into your project and add the following snippet to the header:

<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.0.2/jquery.min.js" type="text/javascript"></script>
<script src="javascript/jquery.growl.js" type="text/javascript"></script>
<link href="stylesheets/jquery.growl.css" rel="stylesheet" type="text/css" />

This plugin is also registered under http://bower.io/ to simplify integration. Try:

npm install -g bower
bower install growl

Gemfile

+ source 'https://rails-assets.org'
...
+ gem 'rails-assets-growl'

application.css

/*
 ...
 *= require growl
 ...
*/

application.js

//= require jquery
...
//= require growl

Examples

Growling is easy:

<script type="text/javascript">
  $.growl({ title: "Growl", message: "The kitten is awake!", url: "/kittens" });
  $.growl.error({ message: "The kitten is attacking!" });
  $.growl.notice({ message: "The kitten is cute!" });
  $.growl.warning({ message: "The kitten is ugly!" });
</script>

Advanced Options

Growl also supports some customization through the following options:

  • delayOnHover: while hovering over the alert, prevent it from being dismissed (true | false - default: true)
  • duration: the duration (in milliseconds) for which the alert is displayed (default: 3200)
  • fixed: whether the alert should be fixed rather than auto-dismissed (true | false - default: false)
  • location: the alert's position ('tl' | 'tr' | 'bl' | 'br' | 'tc' | 'bc' - default: 'tr')
  • size: the alert's size ('small' | 'medium' | 'large' - default: 'medium')
  • style: the alert's style ('default' | 'error' | 'notice' | 'warning' - default: 'default')

Deprecations

  • static has been renamed to fixed due to minifier incompatabilities

Status

Status

Copyright

Copyright (c) 2010 - 2018 Kevin Sylvestre. See LICENSE for details.




鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap