File tree Expand file tree Collapse file tree 5 files changed +14
-11
lines changed Expand file tree Collapse file tree 5 files changed +14
-11
lines changed Original file line number Diff line number Diff line change @@ -261,11 +261,14 @@ grunt.initConfig({
261
261
files : grunt . file . expandFiles ( "tests/unit/**/*.html" ) . filter ( function ( file ) {
262
262
// disabling everything that doesn't (quite) work with PhantomJS for now
263
263
// except for all|index|test, try to include more as we go
264
- return ! ( / ( a l l | i n d e x | t e s t | d r a g g a b l e | d r o p p a b l e | s e l e c t a b l e | r e s i z a b l e | s o r t a b l e | d i a l o g | s l i d e r | d a t e p i c k e r | t a b s | t a b s _ d e p r e c a t e d ) \. h t m l / ) . test ( file ) ;
264
+ return ! ( / ( a l l | a l l - a c t i v e | i n d e x | t e s t | d r a g g a b l e | d r o p p a b l e | s e l e c t a b l e | r e s i z a b l e | s o r t a b l e | d i a l o g | s l i d e r | d a t e p i c k e r | t a b s | t a b s _ d e p r e c a t e d ) \. h t m l / ) . test ( file ) ;
265
265
} )
266
266
} ,
267
267
lint : {
268
- ui : "ui/*" ,
268
+ ui : grunt . file . expandFiles ( "ui/*.js" ) . filter ( function ( file ) {
269
+ // remove items from this list once rewritten
270
+ return ! ( / ( e f f e c t s .c o r e | m o u s e | d a t e p i c k e r | d r a g g a b l e | d r o p p a b l e | r e s i z a b l e | s e l e c t a b l e | s o r t a b l e ) \. j s $ / ) . test ( file ) ;
271
+ } ) ,
269
272
grunt : "grunt.js" ,
270
273
tests : "tests/unit/**/*.js"
271
274
} ,
Original file line number Diff line number Diff line change @@ -107,13 +107,13 @@ $.widget( "ui.autocomplete", {
107
107
// which causes forms to submit
108
108
suppressKeyPress = true ;
109
109
event . preventDefault ( ) ;
110
+ self . menu . select ( event ) ;
110
111
}
111
- //passthrough - ENTER and TAB both select the current element
112
+ break ;
112
113
case keyCode . TAB :
113
- if ( ! self . menu . active ) {
114
- return ;
114
+ if ( self . menu . active ) {
115
+ self . menu . select ( event ) ;
115
116
}
116
- self . menu . select ( event ) ;
117
117
break ;
118
118
case keyCode . ESCAPE :
119
119
if ( self . menu . element . is ( ":visible" ) ) {
@@ -524,7 +524,7 @@ $.widget( "ui.autocomplete", {
524
524
525
525
$ . extend ( $ . ui . autocomplete , {
526
526
escapeRegex : function ( value ) {
527
- return value . replace ( / [ - [ \] { } ( ) * + ? . , \\ ^ $ | # \s ] / g, "\\$&" ) ;
527
+ return value . replace ( / [ \- \ [\] { } ( ) * + ? . , \ \\^ $ | # \s ] / g, "\\$&" ) ;
528
528
} ,
529
529
filter : function ( array , term ) {
530
530
var matcher = new RegExp ( $ . ui . autocomplete . escapeRegex ( term ) , "i" ) ;
Original file line number Diff line number Diff line change @@ -189,7 +189,7 @@ $.widget( "ui.menu", {
189
189
character = prev + character ;
190
190
}
191
191
function escape ( value ) {
192
- return value . replace ( / [ - [ \] { } ( ) * + ? . , \\ ^ $ | # \s ] / g , "\\$&" ) ;
192
+ return value . replace ( / [ \- \ [\] { } ( ) * + ? . , \\ \ ^$ | # \s ] / g, "\\$&" ) ;
193
193
}
194
194
match = this . activeMenu . children ( ".ui-menu-item" ) . filter ( function ( ) {
195
195
return new RegExp ( "^" + escape ( character ) , "i" )
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ $.ui = $.ui || {};
13
13
14
14
var rhorizontal = / l e f t | c e n t e r | r i g h t / ,
15
15
rvertical = / t o p | c e n t e r | b o t t o m / ,
16
- roffset = / [ + - ] \d + % ? / ,
16
+ roffset = / [ \+ \ -] \d + % ? / ,
17
17
rposition = / ^ \w + / ,
18
18
rpercent = / % $ / ,
19
19
center = "center" ,
Original file line number Diff line number Diff line change @@ -162,7 +162,7 @@ $.widget( "ui.tabs", {
162
162
} ,
163
163
164
164
_sanitizeSelector : function ( hash ) {
165
- return hash ? hash . replace ( / [ ! " $ % & ' ( ) * + , . \/ : ; < = > ? @ [ \] ^ ` { | } ~ ] / g, "\\$&" ) : "" ;
165
+ return hash ? hash . replace ( / [ ! " $ % & ' ( ) * + , . \/ : ; < = > ? @ \ [\] \ ^` { | } ~ ] / g, "\\$&" ) : "" ;
166
166
} ,
167
167
168
168
refresh : function ( ) {
@@ -841,7 +841,7 @@ if ( $.uiBackCompat !== false ) {
841
841
842
842
_tabId : function ( a ) {
843
843
return $ ( a ) . attr ( "aria-controls" ) ||
844
- a . title && a . title . replace ( / \s / g, "_" ) . replace ( / [ ^ \w \u00c0 - \uFFFF - ] / g, "" ) ||
844
+ a . title && a . title . replace ( / \s / g, "_" ) . replace ( / [ ^ \w \u00c0 - \uFFFF \ -] / g, "" ) ||
845
845
this . options . idPrefix + getNextTabId ( ) ;
846
846
}
847
847
} ) ;
You can’t perform that action at this time.
0 commit comments