Skip to content

Commit

Permalink
Merge pull request #4521 from jeanp413/jp/fix-forced-reflow
Browse files Browse the repository at this point in the history
Avoid triggering a reflow while rendering search decorations
  • Loading branch information
Tyriar committed May 17, 2023
2 parents 1dbc1bf + 07e8f86 commit a0493a6
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions addons/xterm-addon-search/src/SearchAddon.ts
Original file line number Diff line number Diff line change
Expand Up @@ -693,9 +693,6 @@ export class SearchAddon extends Disposable implements ITerminalAddon {
* @returns
*/
private _applyStyles(element: HTMLElement, borderColor: string | undefined, isActiveResult: boolean): void {
if (element.clientWidth <= 0) {
return;
}
if (!element.classList.contains('xterm-find-result-decoration')) {
element.classList.add('xterm-find-result-decoration');
if (borderColor) {
Expand Down

0 comments on commit a0493a6

Please sign in to comment.