File tree Expand file tree Collapse file tree 1 file changed +10
-6
lines changed Expand file tree Collapse file tree 1 file changed +10
-6
lines changed Original file line number Diff line number Diff line change 80
80
dialog : '<div class="bootbox modal" tabindex="-1" role="dialog" aria-hidden="true"><div class="modal-dialog"><div class="modal-content"><div class="modal-body"><div class="bootbox-body"></div></div></div></div></div>' ,
81
81
header : '<div class="modal-header"><h5 class="modal-title"></h5></div>' ,
82
82
footer : '<div class="modal-footer"></div>' ,
83
- closeButton : '<button type="button" class="bootbox-close-button close btn-close" aria-hidden="true"></button>' ,
83
+ closeButton : '<button type="button" class="bootbox-close-button close btn-close" aria-hidden="true" aria-label="Close" ></button>' ,
84
84
form : '<form class="bootbox-form"></form>' ,
85
85
button : '<button type="button" class="btn"></button>' ,
86
86
option : '<option value=""></option>' ,
379
379
closeButton . html ( '×' ) ;
380
380
}
381
381
382
- if ( options . bootstrap > 3 ) {
383
- dialog . find ( '.modal-header' ) . append ( closeButton ) ;
384
- }
385
- else {
386
- dialog . find ( '.modal-header' ) . prepend ( closeButton ) ;
382
+ /* Note: the close button for Bootstrap 5+ does not contain content */
383
+ if ( options . bootstrap < 5 ) {
384
+ if ( options . bootstrap == 4 ) {
385
+ dialog . find ( '.modal-header' ) . append ( closeButton ) ;
386
+ }
387
+ else {
388
+ /* Bootstrap 3 and under */
389
+ dialog . find ( '.modal-header' ) . prepend ( closeButton ) ;
390
+ }
387
391
}
388
392
}
389
393
}
You can’t perform that action at this time.
0 commit comments