Remove circular dependency

This commit is contained in:
Bruno Ribeito
2019-03-10 22:03:38 +00:00
parent 525af9c36a
commit b4bef0986c
3 changed files with 10 additions and 12 deletions
+4 -4
View File
@@ -5,7 +5,7 @@
import { CHAR_DATA_CHAR_INDEX, CHAR_DATA_ATTR_INDEX, CHAR_DATA_WIDTH_INDEX, CHAR_DATA_CODE_INDEX, NULL_CELL_CODE, WHITESPACE_CELL_CHAR } from '../../Buffer';
import { FLAGS } from '../Types';
import { IBufferLine, ITerminal } from '../../Types';
import { IBufferLine, ITerminalOptions } from '../../Types';
import { DEFAULT_COLOR, INVERTED_DEFAULT_COLOR } from '../atlas/Types';
export const BOLD_CLASS = 'xterm-bold';
@@ -17,7 +17,7 @@ export const CURSOR_STYLE_UNDERLINE_CLASS = 'xterm-cursor-underline';
export class DomRendererRowFactory {
constructor(
private _terminal: ITerminal,
private _terminalOptions: ITerminalOptions,
private _document: Document
) {
}
@@ -89,10 +89,10 @@ export class DomRendererRowFactory {
}
}
if (flags & FLAGS.BOLD && this._terminal.options.enableBold) {
if (flags & FLAGS.BOLD && this._terminalOptions.enableBold) {
// Convert the FG color to the bold variant. This should not happen when
// the fg is the inverse default color as there is no bold variant.
if (fg < 8 && this._terminal.options.drawBoldTextInBrightColors) {
if (fg < 8 && this._terminalOptions.drawBoldTextInBrightColors) {
fg += 8;
}
charElement.classList.add(BOLD_CLASS);