Quellcode durchsuchen

feat(EditorPanel): Add save button to editor toolbar

- Add primary save button with SaveOutlined icon to editor toolbar
- Implement onClick handler for document saving functionality
- Display loading state during save operation
- Add tooltip text "保存文档" for better UX
- Position save button between export and divider for logical flow
- Improve document management workflow by providing direct save action
Zhang Yice vor 2 Monaten
Ursprung
Commit
80f236f4a2
1 geänderte Dateien mit 10 neuen und 0 gelöschten Zeilen
  1. 10 0
      src/components/EditorPanel/EditorPanel.tsx

+ 10 - 0
src/components/EditorPanel/EditorPanel.tsx

@@ -251,6 +251,16 @@ export const EditorPanel: React.FC<EditorPanelProps> = ({
251 251
           >
252 252
             导出
253 253
           </Button>
254
+          <Button
255
+            type="primary"
256
+            size="small"
257
+            icon={<SaveOutlined />}
258
+            onClick={handleSave}
259
+            loading={saving}
260
+            title="保存文档"
261
+          >
262
+            保存
263
+          </Button>
254 264
           <Divider type="vertical" style={{ margin: '0 4px' }} />
255 265
           <Button
256 266
             type="text"