@@ -27,6 +27,7 @@ import { ShowHelp } from '../field/enum';
2727import autobind from '../_util/autobind' ;
2828import { TextAreaProps } from '../text-area/TextArea' ;
2929import { ResizeType } from '../text-area/enum' ;
30+ import { IntlType } from '../intl-field/enum' ;
3031import { ColumnLock } from './enum' ;
3132import transform from '../_util/transform' ;
3233import { LabelLayout , ShowValidation } from '../form/enum' ;
@@ -39,6 +40,10 @@ function isTextArea(editor: ReactElement<FormFieldProps>): editor is ReactElemen
3940 return ( editor . type as any ) . __PRO_TEXTAREA ;
4041}
4142
43+ function isIntlField ( editor : ReactElement < FormFieldProps > ) : boolean {
44+ return ( editor . type as any ) . __PRO_INTLFIELD ;
45+ }
46+
4247function isHTMLElement ( el ) : el is HTMLElement {
4348 return el ;
4449}
@@ -553,6 +558,8 @@ export default class TableEditor extends Component<TableEditorProps> {
553558 if ( height !== undefined ) {
554559 style . height = pxToRem ( height , true ) ;
555560 }
561+ const isMultipleLineIntlField = isIntlField ( cellEditor ) && this . editorProps . type === IntlType . multipleLine ;
562+ const isTextAreaEditor = isTextArea ( cellEditor ) && ( ! isIntlField ( cellEditor ) || isMultipleLineIntlField ) ;
556563 const newEditorProps = {
557564 ...otherProps ,
558565 style,
@@ -561,7 +568,7 @@ export default class TableEditor extends Component<TableEditorProps> {
561568 name,
562569 tagRenderer,
563570 onKeyDown : this . handleEditorKeyDown ,
564- onEnterDown : isTextArea ( cellEditor ) ? undefined : this . handleEditorKeyEnterDown ,
571+ onEnterDown : isTextAreaEditor ? undefined : this . handleEditorKeyEnterDown ,
565572 onBlur : this . handleEditorBlur ,
566573 tabIndex : currentEditorName ? 0 : - 1 ,
567574 showHelp : ShowHelp . none ,
0 commit comments