File tree Expand file tree Collapse file tree 3 files changed +44
-5
lines changed Expand file tree Collapse file tree 3 files changed +44
-5
lines changed Original file line number Diff line number Diff line change 1
1
.algolia-autocomplete {
2
2
width : 100% ;
3
3
4
- . ds-dataset-1 {
4
+ [class^ = " ds-dataset-" ] {
5
5
.algolia-docsearch-suggestion--text {
6
6
.algolia-docsearch-suggestion--highlight {
7
7
box-shadow : inset 0 -2px 0 0 rgba (68 , 168 , 179 ,.8 )
12
12
background : rgba (68 , 168 , 179 , .1 )
13
13
}
14
14
}
15
+ }
16
+
17
+ @media (max-width : 768px ) {
18
+
19
+ .algolia-autocomplete.algolia-autocomplete-right {
20
+ .ds-dropdown-menu {
21
+ width : 100vw !important ;
22
+ max-width : ~ " calc(100vw - 32px) !important" ;
23
+ min-width : ~ " calc(100vw - 32px) !important" ;
24
+ }
25
+
26
+ .algolia-docsearch-suggestion.algolia-docsearch-suggestion .algolia-docsearch-suggestion--subcategory-column {
27
+ display : none ;
28
+
29
+ & :before {
30
+ display : none ;
31
+ }
32
+ }
33
+ .algolia-docsearch-suggestion.algolia-docsearch-suggestion .algolia-docsearch-suggestion--content {
34
+ width : 100% ;
35
+
36
+ & :before {
37
+ display : none ;
38
+ }
39
+ }
40
+ }
15
41
}
Original file line number Diff line number Diff line change 5
5
6
6
@section (' body' )
7
7
<div class =" min-h-screen" >
8
- <div class =" border-b border-smoke flex-none px-8 py-6 w-14 /5 md:w-full md:max-w-xs fixed border-smoke bg-smoke-light border-r-2 z-50" >
8
+ <div class =" hidden border-b border-smoke flex-none px-8 py-6 w-4 /5 md:w-full md:max-w-xs flex-none border-r-2 border-smoke md:flex flex-col fixed border-smoke bg-smoke-light border-r-2 z-50" >
9
9
<div class =" mb-4" >
10
10
<div class =" hidden md:flex md:justify-center" >
11
11
<a href =" /" class =" flex justify-center" >
23
23
</div >
24
24
</div >
25
25
</div >
26
+
26
27
<div id =" sidebar" class =" hidden z-40 fixed pin-y pin-l overflow-y-scroll scrolling-touch bg-smoke-light w-4/5 md:w-full md:max-w-xs flex-none border-r-2 border-smoke md:flex flex-col" >
27
28
<div class =" p-8 flex-1 overflow-y-scroll" >
28
29
<nav id =" nav" class =" text-base overflow-y-scroll" >
177
178
<svg class =" w-4 h-4 cursor-pointer text-grey" role =" button" xmlns =" http://www.w3.org/2000/svg" viewBox =" 0 0 20 20" ><path d =" M10 8.586L2.929 1.515 1.515 2.929 8.586 10l-7.071 7.071 1.414 1.414L10 11.414l7.071 7.071 1.414-1.414L11.414 10l7.071-7.071-1.414-1.414L10 8.586z" /></svg >
178
179
</div >
179
180
</div >
181
+ <div id =" search-mobile" class =" absolute pin-r pin-y px-4 flex items-center relative" >
182
+ <input type =" text" id =" searchbox-mobile" class =" rounded bg-white border border-smoke py-2 pr-4 pl-10 block w-full opacity-75 ds-input" >
183
+ <div class =" pointer-events-none absolute pin-y pin-l pl-8 flex items-center opacity-75" >
184
+ <svg class =" pointer-events-none text-slate w-4 h-4" xmlns =" http://www.w3.org/2000/svg" viewBox =" 0 0 20 20" ><path d =" M12.9 14.32a8 8 0 1 1 1.41-1.41l5.35 5.33-1.42 1.42-5.33-5.34zM8 14A6 6 0 1 0 8 2a6 6 0 0 0 0 12z" /></svg >
185
+ </div >
186
+ </div >
180
187
</div >
181
188
</div >
182
189
<div id =" content" class =" px-6 pb-8 pt-20 md:pt-16 w-full max-w-lg mx-auto" >
Original file line number Diff line number Diff line change 28
28
<script type =" text/javascript" src =" https://cdn.jsdelivr.net/docsearch.js/2/docsearch.min.js" ></script >
29
29
<script type =" text/javascript" >
30
30
docsearch ({
31
- // appId: 'FMDGKF8GP7',
32
31
apiKey: ' 3df93446658cd9c4e314d4c02a052188' ,
33
32
indexName: ' tailwindcss' ,
34
- inputSelector: ' #searchbox' ,
35
- debug: true // Set debug to true if you want to inspect the dropdown
33
+ inputSelector: ' #searchbox'
34
+ });
35
+
36
+ // For mobile ( will be fixed soon, see : https://github.com/algolia/docsearch/issues/230 )
37
+ docsearch ({
38
+ apiKey: ' 3df93446658cd9c4e314d4c02a052188' ,
39
+ indexName: ' tailwindcss' ,
40
+ inputSelector: ' #searchbox-mobile' ,
41
+ debug: true
36
42
});
37
43
</script >
38
44
<script >
You can’t perform that action at this time.
0 commit comments