File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -156,6 +156,15 @@ $.widget("ui.dialog", {
156
156
"aria-labelledby" : uiDialogTitle . attr ( "id" )
157
157
} ) ;
158
158
159
+ // We assume that any existing aria-describedby attribute means
160
+ // that the dialog content is marked up properly
161
+ // otherwise we brute force the content as the description
162
+ if ( ! this . element . find ( "[aria-describedby]" ) . length ) {
163
+ uiDialog . attr ( {
164
+ "aria-describedby" : this . element . uniqueId ( ) . attr ( "id" )
165
+ } ) ;
166
+ }
167
+
159
168
uiDialogTitlebar . find ( "*" ) . add ( uiDialogTitlebar ) . disableSelection ( ) ;
160
169
this . _hoverable ( uiDialogTitlebarClose ) ;
161
170
this . _focusable ( uiDialogTitlebarClose ) ;
@@ -205,6 +214,7 @@ $.widget("ui.dialog", {
205
214
}
206
215
this . uiDialog . hide ( ) ;
207
216
this . element
217
+ . removeUniqueId ( )
208
218
. removeClass ( "ui-dialog-content ui-widget-content" )
209
219
. hide ( )
210
220
. appendTo ( "body" ) ;
You can’t perform that action at this time.
0 commit comments