File tree 3 files changed +16
-6
lines changed
templates/default/fulldoc/html
3 files changed +16
-6
lines changed Original file line number Diff line number Diff line change 85
85
@media (max-width : 320px ) {
86
86
body { height : 100% ; overflow : hidden; overflow-wrap : break-word; }
87
87
# main { height : 100% ; overflow : auto; }
88
- # search { display : none; }
89
88
}
90
89
91
90
# main img { max-width : 100% ; }
@@ -389,6 +388,16 @@ ul.fullTree li:last-child { padding-bottom: 0; }
389
388
text-align : center;
390
389
}
391
390
391
+ .visually-hidden {
392
+ position : absolute;
393
+ top : auto;
394
+ overflow : hidden;
395
+ clip : rect (1px , 1px , 1px , 1px );
396
+ width : 1px ;
397
+ height : 1px ;
398
+ white-space : nowrap;
399
+ }
400
+
392
401
# menu { font-size : 1.3em ; color : # bbb ; }
393
402
# menu .title , # menu a { font-size : 0.7em ; }
394
403
# menu .title a { font-size : 1em ; }
Original file line number Diff line number Diff line change @@ -108,7 +108,7 @@ function enableSearch() {
108
108
}
109
109
} ) ;
110
110
111
- $ ( '#full_list' ) . after ( "<div id='noresults' role='status' style='display:none '></div>" ) ;
111
+ $ ( '#full_list' ) . after ( "<div id='noresults' role='status' style='visually-hidden '></div>" ) ;
112
112
}
113
113
114
114
function ignoredKeyPress ( event ) {
@@ -136,7 +136,7 @@ function clearSearch() {
136
136
function performSearch ( searchString ) {
137
137
clearSearchTimeout ( ) ;
138
138
$ ( '#full_list, #content' ) . addClass ( 'insearch' ) ;
139
- $ ( '#noresults' ) . text ( '' ) . hide ( ) ;
139
+ $ ( '#noresults' ) . text ( '' ) . addClass ( 'visually-hidden' ) ;
140
140
partialSearch ( searchString , 0 ) ;
141
141
}
142
142
@@ -173,11 +173,12 @@ function searchDone() {
173
173
highlight ( ) ;
174
174
var found = $ ( '#full_list li:visible' ) . size ( ) ;
175
175
if ( found === 0 ) {
176
- $ ( '#noresults' ) . text ( 'No results were found.' ) . hide ( ) . fadeIn ( ) ;
176
+ $ ( '#noresults' ) . text ( 'No results were found.' ) ;
177
177
} else {
178
178
// This is read out to screen readers
179
- $ ( '#noresults' ) . text ( 'There are ' + found + ' results.' ) . hide ( ) . fadeIn ( ) ;
179
+ $ ( '#noresults' ) . text ( 'There are ' + found + ' results.' ) ;
180
180
}
181
+ $ ( '#noresults' ) . removeClass ( 'visually-hidden' ) ;
181
182
$ ( '#content' ) . removeClass ( 'insearch' ) ;
182
183
}
183
184
Original file line number Diff line number Diff line change @@ -232,7 +232,7 @@ def class_list(root = Registry.root, tree = TreeContext.new)
232
232
out << "<li id='object_#{ child . path } ' class='#{ tree . classes . join ( ' ' ) } '>"
233
233
out << "<div class='item' style='padding-left:#{ tree . indent } '>"
234
234
accessible_props = "aria-label='#{ name } child nodes' aria-expanded='false' aria-controls='object_#{ child . path } '"
235
- out << "<a tabindex='0' class='toggle' #{ accessible_props } ></a> " if has_children
235
+ out << "<a tabindex='0' class='toggle' role='button' #{ accessible_props } ></a> " if has_children
236
236
out << linkify ( child , name )
237
237
out << " < #{ child . superclass . name } " if child . is_a? ( CodeObjects ::ClassObject ) && child . superclass
238
238
out << "<small class='search_info'>"
You can’t perform that action at this time.
0 commit comments