clear search change to doctor name

This commit is contained in:
Arezoo
2025-10-26 12:54:42 +03:30
parent 7c320d3c22
commit 8ab33b4e93
3 changed files with 35 additions and 57 deletions
+1 -6
View File
@@ -56,7 +56,7 @@ function AutoComplete({
return (
<Autocomplete
freeSolo
options={data}
options={Array.isArray(data) ? data : []} // ✅ همیشه آرایه
getOptionLabel={(option) =>
typeof option === "string" ? option : option.name
}
@@ -65,11 +65,6 @@ function AutoComplete({
className="!w-full"
onInputChange={onInputChange}
onChange={onChange}
renderOption={(props, option) => (
<li {...props} key={option.id}>
{option.name}
</li>
)}
sx={{
"& .MuiAutocomplete-input": {
background: noneBg ? "" : "#ffffff !important",