mirror of
				https://github.com/ZetaKebab/quartz.git
				synced 2025-11-03 22:49:47 +00:00 
			
		
		
		
	fix: search highlight not showing because for trailing slash (#306)
This commit is contained in:
		
				
					committed by
					
						
						GitHub
					
				
			
			
				
	
			
			
			
						parent
						
							b7c305e002
						
					
				
				
					commit
					db27557aa3
				
			@@ -117,7 +117,7 @@ const resultToHTML = ({ url, title, content }) => {
 | 
			
		||||
const redir = (id, term) => {
 | 
			
		||||
  const shouldTrim = PRODUCTION && SEARCH_ENABLED
 | 
			
		||||
  const baseURLPrefix = shouldTrim ? "" : BASE_URL.replace(/\/$/g, "")
 | 
			
		||||
  const urlString = `${baseURLPrefix}${id}#:~:text=${encodeURIComponent(term)}/`
 | 
			
		||||
  const urlString = `${baseURLPrefix}${id}#:~:text=${encodeURIComponent(term)}`
 | 
			
		||||
  window.Million.navigate(
 | 
			
		||||
    new URL(urlString),
 | 
			
		||||
    ".singlePage",
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user