Skip to content

Commit

Permalink
Fix LineHighlight plugin horizontal scroll (#313)
Browse files Browse the repository at this point in the history
  • Loading branch information
jfcere authored May 22, 2021
1 parent d22d745 commit 71b65bf
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 2 deletions.
1 change: 0 additions & 1 deletion lib/src/markdown.component.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,6 @@ describe('MarkdownComponent', () => {
component.line = '6, 10-16';
component.render(markdown);

expect(getHTMLPreElement()?.classList).toContain('line-highlight');
expect(getHTMLPreElement()?.attributes.getNamedItem('data-line')?.value).toBe('6, 10-16');
expect(getHTMLPreElement()?.attributes.getNamedItem('data-line-offset')).toBeNull();

Expand Down
1 change: 0 additions & 1 deletion lib/src/markdown.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,6 @@ export class MarkdownComponent implements OnChanges, AfterViewInit {

private handlePlugins(): void {
if (this.lineHighlight) {
this.setPluginClass(this.element.nativeElement, PrismPlugin.LineHighlight);
this.setPluginOptions(this.element.nativeElement, { dataLine: this.line, dataLineOffset: this.lineOffset });
}
if (this.lineNumbers) {
Expand Down

0 comments on commit 71b65bf

Please sign in to comment.