From 528beaa9b3cbc31513657bad30b4e0408c33a8f1 Mon Sep 17 00:00:00 2001 From: GCWing Date: Thu, 12 Feb 2026 20:42:33 +0800 Subject: [PATCH] fix: Fix button style on the config page --- package-lock.json | 6 +++--- .../config/components/EditorConfig.scss | 17 +++++++++++++++++ .../config/components/EditorConfig.tsx | 12 +++++++----- 3 files changed, 27 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 3cd8233f..c4f40692 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "BitFun", - "version": "0.1.0-alpha.1(dev)", + "version": "0.1.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "BitFun", - "version": "0.1.0-alpha.1(dev)", + "version": "0.1.0", "hasInstallScript": true, "dependencies": { "@codemirror/autocomplete": "^6.18.7", @@ -18,7 +18,7 @@ "@lezer/highlight": "^1.2.1", "@monaco-editor/react": "^4.6.0", "@react-sigma/core": "^5.0.6", - "@tauri-apps/api": "~2.9.0", + "@tauri-apps/api": "^2", "@tauri-apps/plugin-dialog": "^2.6", "@tauri-apps/plugin-fs": "^2", "@tauri-apps/plugin-log": "^2.8.0", diff --git a/src/web-ui/src/infrastructure/config/components/EditorConfig.scss b/src/web-ui/src/infrastructure/config/components/EditorConfig.scss index 5f252c8a..1f8600eb 100644 --- a/src/web-ui/src/infrastructure/config/components/EditorConfig.scss +++ b/src/web-ui/src/infrastructure/config/components/EditorConfig.scss @@ -286,6 +286,23 @@ $config-section-gap: 16px; } +// Action buttons +.config-action-buttons { + display: flex; + align-items: center; + gap: $size-gap-3; + margin-top: $size-gap-5; + padding-top: $size-gap-4; + border-top: 1px solid var(--border-accent-soft); + + &__saving { + font-size: 13px; + color: var(--color-text-muted); + font-style: italic; + } +} + + @media (max-width: 768px) { .config-form-row { grid-template-columns: 1fr; diff --git a/src/web-ui/src/infrastructure/config/components/EditorConfig.tsx b/src/web-ui/src/infrastructure/config/components/EditorConfig.tsx index 94d2c092..ed171a50 100644 --- a/src/web-ui/src/infrastructure/config/components/EditorConfig.tsx +++ b/src/web-ui/src/infrastructure/config/components/EditorConfig.tsx @@ -2,7 +2,8 @@ import React, { useState, useEffect, useCallback, useRef } from 'react'; import { useTranslation } from 'react-i18next'; -import { NumberInput, Select } from '@/component-library'; +import { NumberInput, Select, Button } from '@/component-library'; +import { RotateCcw } from 'lucide-react'; import { configManager } from '../services/ConfigManager'; import { globalEventBus } from '@/infrastructure/event-bus'; import { DEFAULT_EDITOR_CONFIG, type EditorConfig as EditorConfigType, type EditorConfigPartial } from '@/tools/editor/config'; @@ -623,14 +624,15 @@ const EditorConfig: React.FC = () => {
- + {isSaving && ( {t('messages.saving')} )}