xtermjs/xterm.js

Auto fit addon doesn't work when parent element uses border-box

Open

#1,283 创建于 2018年2月12日

在 GitHub 查看
 (4 评论) (0 反应) (1 负责人)TypeScript (1,574 fork)batch import
area/addon/fitgood first issuehelp wantedtype/bug

仓库指标

Star
 (16,196 star)
PR 合并指标
 (平均合并 2天 10小时) (30 天内合并 16 个 PR)

描述

The calculations for height and width of the parent in the auto fit plugin are incorrect when the parent element uses box-sizing: border-box. This is because the computed height includes the padding but the content does not.

The right implementation might be to get the client height of the parent element using gBCR and then subtract the parent padding.

/CC @taion

贡献者指南