Fix EkriKomante ref
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import {useCallback, useEffect, useState} from 'react'
|
||||
import {useCallback, useEffect, useState, forwardRef} from 'react'
|
||||
import PropTypes from 'prop-types'
|
||||
import axios from 'axios'
|
||||
import {
|
||||
@@ -13,10 +13,9 @@ import MuiAlert from '@mui/material/Alert'
|
||||
|
||||
const API_URL = process.env.NEXT_PUBLIC_API_URL || 'http://localhost:1337'
|
||||
|
||||
function Alert(props) {
|
||||
return <MuiAlert elevation={6} variant='filled' {...props} />
|
||||
}
|
||||
|
||||
const Alert = forwardRef(function Alert(props, ref) {
|
||||
return <MuiAlert ref={ref} elevation={6} variant='filled' {...props} />
|
||||
})
|
||||
function EkriKomante({session, teks, meteEsKomanteOuve}) {
|
||||
const {jwt, user} = session
|
||||
const {_id} = teks
|
||||
|
||||
Reference in New Issue
Block a user