Reuse text element computed styles if applicable
This commit is contained in:
@@ -332,7 +332,10 @@ class BesService {
|
||||
this.correctionPanel.style.paddingRight = styles.paddingRight
|
||||
this.scrollPanel.style.width = `${this.textElement.scrollWidth}px`
|
||||
if (this.isHostElementInline()) {
|
||||
const hStyles = window.getComputedStyle(this.hostElement)
|
||||
const hStyles =
|
||||
this.hostElement !== this.textElement
|
||||
? window.getComputedStyle(this.hostElement)
|
||||
: styles
|
||||
const totalWidth =
|
||||
parseFloat(styles.paddingLeft) +
|
||||
parseFloat(styles.marginLeft) +
|
||||
|
Reference in New Issue
Block a user