1

text fieldmat-expansion panel. space输入单词时无法添加Dinbert Syndrome。当我点击空间down arrow open the panel

Below is the image after typed 1st word (Arrow is intact and downwards)

在此处输入图像描述

When pressed space, no space is applied but panel opens (arrow upwards)

单击空格时,面板打开但未应用空格

预期-Dinbert Syndrome

我得到的文字-DinbertSyndrome

.html

  <mat-expansion-panel-header>
              <mat-panel-title>
                <dt class="col-sm-4 record_property">Product</dt>
              </mat-panel-title>
              <mat-panel-description>
                <dd class="col-sm-8 record_property_value Product_name" id="{{genProductId(product.name)}}">
                  <internal-edit id="concept_{{ci}}_Product_{{ti}}_edit" *ngIf="product.$new" [(field)]="product.name"
                                       [elementType]="rn.productData" (fieldChange)="ProductModified(product)" cols="30" 
                                       rows="1"></internal-edit>
                </dd>
              </mat-panel-description>
            </mat-expansion-panel-header>
            

内部编辑.html

<internal-edit [editable]="true"
                   [inputTag]="'textarea'"
                   [(inputText)]="field"
                   (inputTextChange)="termModified(field)"
                   [placeholder]="'Term'"></internal-edit>

.ts

genProductId(s: string) {
    return s ? s.replace(/ /g, '_') : '';
  }

注意- 我的 selenium-protractor 端到端测试因此失败。

4

0 回答 0