File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -89,7 +89,7 @@ $.widget( "ui.button", {
89
89
if ( this . options . iconPosition ) {
90
90
this . element . addClass ( "ui-icon-" + this . options . iconPosition ) ;
91
91
}
92
- if ( ! this . options . text ) {
92
+ if ( ! this . options . showLabel ) {
93
93
this . element . addClass ( " ui-button-icon-only" ) ;
94
94
}
95
95
this . element . append ( this . icon ) ;
@@ -125,7 +125,7 @@ $.widget( "ui.button", {
125
125
this . title = this . element . attr ( "title" ) ;
126
126
this . hasTitle = ! ! this . title ;
127
127
128
- if ( ! this . options . text ) {
128
+ if ( ! this . options . showLabel ) {
129
129
if ( ! this . hasTitle ) {
130
130
this . element . attr ( "title" , this . title ) ;
131
131
}
@@ -154,7 +154,7 @@ $.widget( "ui.button", {
154
154
. toggleClass ( this . options . iconPosition , ! ! value ) ;
155
155
this . _setTitle ( ) ;
156
156
}
157
- if ( key === "iconPosition" && this . options . text ) {
157
+ if ( key === "iconPosition" && this . options . showLabel ) {
158
158
this . element . addClass ( value )
159
159
. removeClass ( this . options . iconPosition ) ;
160
160
}
Original file line number Diff line number Diff line change @@ -87,7 +87,7 @@ $.widget( "ui.checkboxradio", {
87
87
} ) ;
88
88
} ,
89
89
90
- enhance : function ( ) {
90
+ _enhance : function ( ) {
91
91
this . element . addClass ( "ui-helper-hidden-accessible ui-checkboxradio" ) ;
92
92
93
93
this . label . addClass ( baseClasses + " ui-" + this . type + "-label" ) ;
@@ -126,8 +126,8 @@ $.widget( "ui.checkboxradio", {
126
126
var ancestor , labelSelector ;
127
127
128
128
// Check control.labels first
129
- if ( this . element [ 0 ] . labels !== undefined ) {
130
- this . label = $ ( this . element [ 0 ] . labels ) ;
129
+ if ( this . element [ 0 ] . labels !== undefined && this . element [ 0 ] . labels . length > 0 ) {
130
+ this . label = $ ( this . element [ 0 ] . labels [ 0 ] ) ;
131
131
} else {
132
132
133
133
// We don't search against the document in case the element
You can’t perform that action at this time.
0 commit comments