File tree Expand file tree Collapse file tree 2 files changed +13
-11
lines changed Expand file tree Collapse file tree 2 files changed +13
-11
lines changed Original file line number Diff line number Diff line change 22
33## 1.126.0 (Unreleased)
44
5+ - Fixed a bug opening non-Quarto files in visual mode on saving (< https://github.com/quarto-dev/quarto/pull/848 > ).
6+
57## 1.125.0 (Release on 2025-09-03)
68
79- Fixed an issue where attribute values containing '='s could be truncated in some scenarios (< https://github.com/quarto-dev/quarto/pull/814 > ).
Original file line number Diff line number Diff line change @@ -129,18 +129,18 @@ export async function reopenEditorInVisualMode(
129129 // reopen in visual mode
130130 commands . executeCommand ( 'positron.reopenWith' , document . uri , 'quarto.visualEditor' ) ;
131131 } else {
132- workspace . onDidSaveTextDocument ( async ( doc : TextDocument ) => {
133- // open in visual mode
134- VisualEditorProvider . recordPendingSwitchToVisual ( doc ) ;
135- await commands . executeCommand ( 'workbench.action.closeActiveEditor' ) ;
136- await commands . executeCommand ( "vscode.openWith" ,
137- doc . uri ,
138- VisualEditorProvider . viewType ,
139- { viewColumn }
140- ) ;
141- } ) ;
142- // save, which will trigger `onDidSaveTextDocument`
132+ // save then close
143133 await commands . executeCommand ( "workbench.action.files.save" ) ;
134+ await commands . executeCommand ( 'workbench.action.closeActiveEditor' ) ;
135+ VisualEditorProvider . recordPendingSwitchToVisual ( document ) ;
136+
137+ // open in visual mode
138+ await commands . executeCommand (
139+ "vscode.openWith" ,
140+ document . uri ,
141+ VisualEditorProvider . viewType ,
142+ { viewColumn }
143+ ) ;
144144 }
145145}
146146
You can’t perform that action at this time.
0 commit comments