Material UI TextField with hyper link

Viewed 674

Pass hyperlink along with text contents as value to TextFeild of material-ui, but it renders as string(seem in pic below)

enter image description here component:

import { TextField, Link } from '@material-ui/core'
...

     return (
        <TextField
          multiline={multiline}
          value={value + `  <Link href="https://google.com">Hello</Link>`}
          onChange={onChange}
          onChangeText={onChangeText}
          onFocus={onFocus}
          onBlur={onBlur}
          placeholderTextColor={placeholderTextColor || color.darkenGrey}
          size={size}
          rows={rows}
          style={style}
          inputStyle={inputStyle}
          defaultValue={defaultValue}
          placeholder={placeholder}
          error={error}
          label={label}
          id={id}
          helperText={helperText}
          FormHelperTextProps={{
            classes: {
              root: helperTextClass,
            },
          }}
          type={type}
        >
          {children}
        </TextField>
      )

how to make textfield render links as clickable hyperlink

0 Answers
Related