Skip to content

Commit

Permalink
rebuild & version bump
Browse files Browse the repository at this point in the history
  • Loading branch information
rvagg committed Aug 2, 2012
1 parent 459651e commit 6d31bb5
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
9 changes: 5 additions & 4 deletions bonzo.js
Expand Up @@ -13,7 +13,7 @@
, html = doc.documentElement
, parentNode = 'parentNode'
, query = null // used for setting a selector engine host
, specialAttributes = /^(checked|value|selected)$/i
, specialAttributes = /^(checked|value|selected|disabled)$/i
, specialTags = /^(select|fieldset|table|tbody|tfoot|td|tr|colgroup)$/i // tags that we have trouble inserting *into*
, table = ['<table>', '</table>', 1]
, td = ['<table><tbody><tr>', '</tr></tbody></table>', 3]
Expand All @@ -29,7 +29,7 @@
, option: option, optgroup: option
, script: noscope, style: noscope, link: noscope, param: noscope, base: noscope
}
, stateAttributes = /^(checked|selected)$/
, stateAttributes = /^(checked|selected|disabled)$/
, ie = /msie/i.test(navigator.userAgent)
, hasClass, addClass, removeClass
, uidMap = {}
Expand Down Expand Up @@ -618,7 +618,7 @@
* @return {Bonzo}
*/
, show: function (opt_type) {
opt_type = typeof opt_type == 'string' ? opt_type : ''
opt_type = typeof opt_type == 'string' ? opt_type : ''
return this.each(function (el) {
el.style.display = opt_type
})
Expand All @@ -642,9 +642,10 @@
*/
, toggle: function (opt_callback, opt_type) {
opt_type = typeof opt_type == 'string' ? opt_type : '';
typeof opt_callback != 'function' && (opt_callback = null)
return this.each(function (el) {
el.style.display = (el.offsetWidth || el.offsetHeight) ? 'none' : opt_type;
typeof opt_callback == 'function' && opt_callback.call(el)
opt_callback && opt_callback.call(el)
})
}

Expand Down

0 comments on commit 6d31bb5

Please sign in to comment.