Open Enzo-web opened 7 months ago
因为一些特殊场景,textarea组件加了css word-spacing。input组件使用autosize 高度自适应,因calcTextareaHeight.ts中的【SIZING_STYLE】未使用word-spacing属性,导致计算的高度可能会存在于实际高度不一致的问题,导致实际内容被切割或无法完整展示。
在calcTextareaHeight.ts中的【SIZING_STYLE】增加word-spacing属性:
const SIZING_STYLE = [ 'word-spacing', 'letter-spacing', 'line-height', 'padding-top', 'padding-bottom', 'font-family', 'font-weight', 'font-size', 'text-rendering', 'text-transform', 'width', 'text-indent', 'padding-left', 'padding-right', 'border-width', 'box-sizing', ];
What problem does this feature solve?
因为一些特殊场景,textarea组件加了css word-spacing。input组件使用autosize 高度自适应,因calcTextareaHeight.ts中的【SIZING_STYLE】未使用word-spacing属性,导致计算的高度可能会存在于实际高度不一致的问题,导致实际内容被切割或无法完整展示。
What does the proposed API look like?
在calcTextareaHeight.ts中的【SIZING_STYLE】增加word-spacing属性:
const SIZING_STYLE = [ 'word-spacing', 'letter-spacing', 'line-height', 'padding-top', 'padding-bottom', 'font-family', 'font-weight', 'font-size', 'text-rendering', 'text-transform', 'width', 'text-indent', 'padding-left', 'padding-right', 'border-width', 'box-sizing', ];