feat: Добавить API для управления настройками пользовательского интерфейса, включая получение и обновление конфигурации из S3; интегрировать модальное окно настроек в интерфейс
Publish Fast Tabler Docker image / build-and-push-fast (push) Successful in 1m33s
Publish Fast Tabler Docker image / build-and-push-fast (push) Successful in 1m33s
This commit is contained in:
@@ -22,6 +22,7 @@ import CommunitiesManager from './CommunitiesManager';
|
||||
import Dashboard from './Dashboard';
|
||||
import './App.css';
|
||||
import { NotifyProvider } from './components/NotifyProvider.jsx';
|
||||
import SettingsModal from './components/SettingsModal.jsx';
|
||||
// axios не используется напрямую; сетевые вызовы через src/lib/api.js
|
||||
|
||||
// --- Simple i18n (RU/EN) ---
|
||||
@@ -96,6 +97,7 @@ function MainLayout() {
|
||||
const { lang, setLang, t } = useContext(LanguageContext);
|
||||
const { theme, setTheme } = useContext(ThemeContext);
|
||||
// Навбар стал лаконичным: без неиспользуемых уведомлений/иконок
|
||||
const [settingsOpen, setSettingsOpen] = useState(false);
|
||||
|
||||
// Состояние для управления выпадающими меню
|
||||
const [dropdownStates, setDropdownStates] = useState({
|
||||
@@ -301,6 +303,11 @@ function MainLayout() {
|
||||
<option value="dark">{t('dark')}</option>
|
||||
</select>
|
||||
</div>
|
||||
<div className="nav-item ms-2">
|
||||
<button className="btn btn-outline-primary btn-sm" onClick={() => setSettingsOpen(true)}>
|
||||
<IconSettings className="me-1" /> Настройки
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</header>
|
||||
@@ -318,6 +325,7 @@ function MainLayout() {
|
||||
<Route path="/" element={<Navigate to="/dashboard" replace />} />
|
||||
</Routes>
|
||||
</div>
|
||||
<SettingsModal open={settingsOpen} onClose={() => setSettingsOpen(false)} />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user