mirror of
https://github.com/jquery/jquery.git
synced 2026-04-20 03:01:22 -04:00
Fix #11309. Recognize hexadecimal in data attributes.
This commit is contained in:
committed by
Dave Methvin
parent
974e4afbe2
commit
96bb57d4ef
@@ -333,7 +333,7 @@ function dataAttr( elem, key, data ) {
|
||||
data = data === "true" ? true :
|
||||
data === "false" ? false :
|
||||
data === "null" ? null :
|
||||
jQuery.isNumeric( data ) ? parseFloat( data ) :
|
||||
jQuery.isNumeric( data ) ? +data :
|
||||
rbrace.test( data ) ? jQuery.parseJSON( data ) :
|
||||
data;
|
||||
} catch( e ) {}
|
||||
|
||||
Reference in New Issue
Block a user