File tree Expand file tree Collapse file tree 2 files changed +8
-1
lines changed
packages/gitbook/src/components/Search Expand file tree Collapse file tree 2 files changed +8
-1
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ " gitbook " : patch
3
+ ---
4
+
5
+ Fix bug in search highlight in GBO
Original file line number Diff line number Diff line change @@ -15,6 +15,8 @@ export function HighlightQuery(props: {
15
15
query,
16
16
text,
17
17
highlight = [
18
+ '-z-1' ,
19
+ 'relative' ,
18
20
'text-bold' ,
19
21
'bg-primary' ,
20
22
'text-contrast-primary' ,
@@ -33,7 +35,7 @@ export function HighlightQuery(props: {
33
35
const matches = matchString ( text , query ) ;
34
36
35
37
return (
36
- < span className = { tcls ( 'whitespace-break-spaces' ) } >
38
+ < span className = { tcls ( 'relative z-2 whitespace-break-spaces' ) } >
37
39
{ matches . map ( ( entry , index ) => (
38
40
< span key = { index } className = { tcls ( entry . match ? highlight : null ) } >
39
41
{ entry . text }
You can’t perform that action at this time.
0 commit comments