/* * Copyright OpenSearch Contributors * SPDX-License-Identifier: Apache-2.0 */ import React from 'react'; import { EuiFlexGroup, EuiFlexItem, EuiToolTip } from '@elastic/eui'; // import { FieldIcon, FieldIconProps } from '../../../../../kibana_react/public'; // import { shortenDottedString } from '../../helpers'; import { getFieldTypeName } from './field_type_name'; // properties fieldType and fieldName are provided in osd_doc_view // this should be changed when both components are deangularized interface Props { fieldName: string; fieldType: string; useShortDots?: boolean; // fieldIconProps?: Omit; scripted?: boolean; } export function FieldName({ fieldName, fieldType, useShortDots, // fieldIconProps, scripted = false, }: Props) { const typeName = getFieldTypeName(fieldType); // const displayName = useShortDots ? shortenDottedString(fieldName) : fieldName; const displayName = fieldName; return ( {/* */} {displayName} ); }