mirror of
https://github.com/microsoft/vscode.git
synced 2026-05-26 18:27:38 +01:00
Set mime to markdown when changing to markdown language mode
Fixes #128873
This commit is contained in:
@@ -1650,7 +1650,7 @@ registerAction2(class ChangeCellLanguageAction extends NotebookCellAction<ICellR
|
||||
|
||||
private async setLanguage(context: IChangeCellContext, languageId: string) {
|
||||
if (languageId === 'markdown' && context.cell?.language !== 'markdown') {
|
||||
const newCell = await changeCellToKind(CellKind.Markup, { cell: context.cell, notebookEditor: context.notebookEditor }, 'markdown');
|
||||
const newCell = await changeCellToKind(CellKind.Markup, { cell: context.cell, notebookEditor: context.notebookEditor }, 'markdown', Mimes.markdown);
|
||||
if (newCell) {
|
||||
context.notebookEditor.focusNotebookCell(newCell, 'editor');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user