Desktop: Fix issue with GotoAnything that would prevent it from highlighting search results in note titles (#11888)

pull/11857/head^2
Laurent Cozic 2025-02-27 16:29:33 +00:00 committed by GitHub
parent bc385d59e9
commit ae8658554f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 4 deletions

View File

@ -23,7 +23,6 @@ import Resource from '@joplin/lib/models/Resource';
import { NoteEntity, ResourceEntity } from '@joplin/lib/services/database/types';
import Dialog from '../gui/Dialog';
import AsyncActionQueue from '@joplin/lib/AsyncActionQueue';
import { htmlentities } from '@joplin/utils/html';
const logger = Logger.create('GotoAnything');
@ -561,9 +560,7 @@ class DialogComponent extends React.PureComponent<Props, State> {
);
};
const titleHtml = item.fragments
? `<span style="font-weight: bold; color: ${theme.color};">${htmlentities(item.title)}</span>`
: wrapKeywordMatches(item.title);
const titleHtml = wrapKeywordMatches(item.title);
const fragmentsHtml = !item.fragments ? null : wrapKeywordMatches(item.fragments);