Spaces:
Running
Running
Update src/App.tsx
Browse files- src/App.tsx +3 -5
src/App.tsx
CHANGED
@@ -1,4 +1,4 @@
|
|
1 |
-
// src/App.tsx (نسخه نهایی با آیکون
|
2 |
import React, { useEffect, useRef, useState, FC } from "react";
|
3 |
import './App.scss';
|
4 |
import { AppProvider, useAppContext, PersonalityType, PersonalityInstructions } from "./contexts/AppContext";
|
@@ -51,8 +51,6 @@ const CustomModal: FC<CustomModalProps> = ({ isOpen, onClose, onSave, initialNam
|
|
51 |
const PersonalityMenu: React.FC<{ isOpen: boolean; onClose: () => void; onSelect: (p: PersonalityType) => void; }> = ({ isOpen, onClose, onSelect }) => {
|
52 |
const menuRef = useRef<HTMLDivElement>(null);
|
53 |
const { selectedPersonality } = useAppContext();
|
54 |
-
// ✅ تغییر اینجا اعمال نمیشود، چون این بخش آیکونهای *داخل* منو را تعیین میکند.
|
55 |
-
// آیکون "person" برای "دستیار پیشفرض" همچنان سر انسان است.
|
56 |
const personalityIcons: Record<PersonalityType, string> = { default: "person", teacher: "school", poetic: "auto_awesome", funny: "sentiment_satisfied", custom: "tune" };
|
57 |
const personalityLabels: Record<PersonalityType, string> = { default: 'دستیار پیشفرض', teacher: 'استاد زبان', poetic: 'حس خوب', funny: 'شوخطبع', custom: 'شخصیت اختصاصی' };
|
58 |
useEffect(() => {
|
@@ -101,8 +99,8 @@ const AppInternal: React.FC = () => {
|
|
101 |
<div className="main-wrapper">
|
102 |
<div className="header-controls">
|
103 |
<button aria-label="انتخاب شخصیت" className="header-icon-button" onClick={() => setIsPersonalityMenuOpen(v => !v)}>
|
104 |
-
{/* ✅ تغییر اصلی
|
105 |
-
<span className="material-symbols-outlined">
|
106 |
</button>
|
107 |
<button ref={notificationButtonRef} aria-label="اطلاعات" className="header-icon-button" onClick={() => setIsNotificationOpen(v => !v)}>
|
108 |
<span className="material-symbols-outlined">info</span>
|
|
|
1 |
+
// src/App.tsx (نسخه نهایی با آیکون manage_accounts)
|
2 |
import React, { useEffect, useRef, useState, FC } from "react";
|
3 |
import './App.scss';
|
4 |
import { AppProvider, useAppContext, PersonalityType, PersonalityInstructions } from "./contexts/AppContext";
|
|
|
51 |
const PersonalityMenu: React.FC<{ isOpen: boolean; onClose: () => void; onSelect: (p: PersonalityType) => void; }> = ({ isOpen, onClose, onSelect }) => {
|
52 |
const menuRef = useRef<HTMLDivElement>(null);
|
53 |
const { selectedPersonality } = useAppContext();
|
|
|
|
|
54 |
const personalityIcons: Record<PersonalityType, string> = { default: "person", teacher: "school", poetic: "auto_awesome", funny: "sentiment_satisfied", custom: "tune" };
|
55 |
const personalityLabels: Record<PersonalityType, string> = { default: 'دستیار پیشفرض', teacher: 'استاد زبان', poetic: 'حس خوب', funny: 'شوخطبع', custom: 'شخصیت اختصاصی' };
|
56 |
useEffect(() => {
|
|
|
99 |
<div className="main-wrapper">
|
100 |
<div className="header-controls">
|
101 |
<button aria-label="انتخاب شخصیت" className="header-icon-button" onClick={() => setIsPersonalityMenuOpen(v => !v)}>
|
102 |
+
{/* ✅ تغییر اصلی اینجاست */}
|
103 |
+
<span className="material-symbols-outlined">manage_accounts</span>
|
104 |
</button>
|
105 |
<button ref={notificationButtonRef} aria-label="اطلاعات" className="header-icon-button" onClick={() => setIsNotificationOpen(v => !v)}>
|
106 |
<span className="material-symbols-outlined">info</span>
|