Skip to content

Commit 3d6e106

Browse files
committed
add algolia-site-verification
1 parent 3cd36e7 commit 3d6e106

File tree

4 files changed

+415
-35
lines changed

4 files changed

+415
-35
lines changed

algolia-site-verification.html

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<meta name="algolia-site-verification" content="84DC8A8A227267EC" />
5+
<title>Algolia Verification</title>
6+
</head>
7+
<body></body>
8+
</html>

assets/css/docsearch.css

Lines changed: 110 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,69 +7,150 @@
77

88
/* Style the DocSearch button to match the original design */
99
.DocSearch-Button {
10-
background: transparent;
10+
background: #fff;
1111
border: 1px solid #ccc;
1212
border-radius: 4px;
1313
padding: 8px 12px;
1414
width: 100%;
15+
max-width: 100%;
1516
font-size: 14px;
1617
color: #333;
1718
cursor: pointer;
1819
transition: border-color 0.2s;
20+
display: flex;
21+
align-items: center;
22+
justify-content: flex-start;
23+
margin: 0;
24+
height: auto;
25+
min-height: 36px;
1926
}
2027

2128
.DocSearch-Button:hover {
2229
border-color: #999;
30+
box-shadow: 0 1px 3px rgba(0,0,0,0.1);
31+
}
32+
33+
.DocSearch-Button:focus {
34+
border-color: #007acc;
35+
outline: none;
36+
box-shadow: 0 0 0 2px rgba(0,122,204,0.2);
2337
}
2438

2539
.DocSearch-Button-Container {
2640
display: flex;
2741
align-items: center;
42+
flex: 1;
2843
}
2944

3045
.DocSearch-Search-Icon {
3146
width: 20px;
3247
height: 20px;
3348
margin-right: 8px;
3449
color: #666;
50+
flex-shrink: 0;
3551
}
3652

3753
.DocSearch-Button-Placeholder {
3854
font-size: 14px;
3955
color: #999;
56+
flex: 1;
57+
text-align: left;
4058
}
4159

4260
.DocSearch-Button-Keys {
43-
display: none; /* Hide keyboard shortcut hints */
61+
display: none; /* Hide keyboard shortcut hints for cleaner look */
4462
}
4563

4664
/* Modal styling to match site theme */
4765
.DocSearch-Modal {
48-
font-family: inherit;
66+
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
67+
}
68+
69+
.DocSearch-Container {
70+
background: rgba(0, 0, 0, 0.6);
71+
}
72+
73+
.DocSearch-Form {
74+
background: #fff;
75+
border: 1px solid #e1e5e9;
76+
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
4977
}
5078

5179
/* Results styling */
5280
.DocSearch-Hit-title {
5381
font-weight: 600;
82+
color: #2c3e50;
5483
}
5584

5685
.DocSearch-Hit-path {
5786
color: #666;
5887
font-size: 12px;
5988
}
6089

90+
.DocSearch-Hit-content-wrapper {
91+
margin-top: 4px;
92+
}
93+
94+
.DocSearch-Hit-snippet {
95+
color: #555;
96+
font-size: 13px;
97+
line-height: 1.4;
98+
}
99+
61100
/* Customize the hit highlighting */
101+
.DocSearch-Hit mark,
62102
mark {
63103
background-color: #ffeb3b;
64104
color: #333;
65105
padding: 1px 2px;
66106
border-radius: 2px;
107+
font-weight: normal;
108+
}
109+
110+
/* Search input styling */
111+
.DocSearch-Input {
112+
font-size: 16px;
113+
color: #333;
114+
}
115+
116+
.DocSearch-Input::placeholder {
117+
color: #999;
67118
}
68119

69120
/* Footer styling */
70121
.DocSearch-Footer {
71122
border-top: 1px solid #eee;
72123
padding-top: 16px;
124+
background: #f8f9fa;
125+
}
126+
127+
/* Hit highlighting when using keyboard navigation */
128+
.DocSearch-Hit[aria-selected="true"] {
129+
background: #f0f7ff;
130+
}
131+
132+
/* No results state */
133+
.DocSearch-NoResults {
134+
text-align: center;
135+
padding: 32px 16px;
136+
}
137+
138+
.DocSearch-NoResults-Prefill-List {
139+
margin-top: 16px;
140+
}
141+
142+
/* Responsive adjustments */
143+
@media (max-width: 768px) {
144+
.DocSearch-Button {
145+
font-size: 16px; /* Prevent zoom on iOS */
146+
padding: 10px 12px;
147+
}
148+
149+
.DocSearch-Modal {
150+
margin: 0;
151+
border-radius: 0;
152+
height: 100vh;
153+
}
73154
}
74155

75156
/* Dark mode adjustments if needed */
@@ -87,4 +168,30 @@ mark {
87168
.DocSearch-Search-Icon {
88169
color: #ccc;
89170
}
171+
172+
.DocSearch-Form {
173+
background: #2a2a2a;
174+
border-color: #555;
175+
}
176+
177+
.DocSearch-Input {
178+
color: #fff;
179+
background: transparent;
180+
}
181+
182+
.DocSearch-Hit-title {
183+
color: #fff;
184+
}
185+
186+
.DocSearch-Hit-path {
187+
color: #ccc;
188+
}
189+
190+
.DocSearch-Hit-snippet {
191+
color: #ddd;
192+
}
193+
194+
.DocSearch-Hit[aria-selected="true"] {
195+
background: #404040;
196+
}
90197
}

docsearch-test.html

Lines changed: 0 additions & 32 deletions
This file was deleted.

0 commit comments

Comments
 (0)