Angular4 mat-form-field textArea 无法启用水平调整大小

Angular4 mat-form-field textArea can not enable horizontal resize

我正在尝试将 mat-form-field 组件与 textarea 一起使用,我希望能够在 x 和 y 上调整大小。 但是添加 resize: both; 并没有使它起作用,解决方案是什么?

代码:

<mat-form-field style="resize: both;">
    <textarea matInput placeholder="Leave a comment"></textarea>
</mat-form-field>

将其应用于 textarea 将允许您在 mat-form-field...

中调整 x 和 y 的大小
<textarea style="resize:both" matInput placeholder="Leave a comment"></textarea>

不幸的是,这只允许文本区域在 form-field

范围内调整大小
  • 包含构成 mat-form-field 的所有嵌套 div 元素 包装器,尝试将其应用于所有这些包装器可能会以嵌套的拖动角结束,而不是一个无缝的可调整大小的元素。