Adopt monaco-editor-core@0.14.0

This commit is contained in:
Alex Dima 2018-08-10 11:58:26 +02:00
parent ac6eafddf5
commit 4336d9c40f
2 changed files with 6 additions and 4 deletions

View file

@ -19,8 +19,8 @@
"url": "https://github.com/Microsoft/monaco-css/issues"
},
"devDependencies": {
"monaco-editor-core": "0.13.2",
"monaco-languages": "1.3.1",
"monaco-editor-core": "0.14.0",
"monaco-languages": "1.4.0",
"monaco-plugin-helpers": "^1.0.2",
"requirejs": "^2.3.5",
"typescript": "3.0.1",

View file

@ -458,7 +458,7 @@ export class DocumentSymbolAdapter implements monaco.languages.DocumentSymbolPro
constructor(private _worker: WorkerAccessor) {
}
public provideDocumentSymbols(model: monaco.editor.IReadOnlyModel, token: CancellationToken): Thenable<monaco.languages.SymbolInformation[]> {
public provideDocumentSymbols(model: monaco.editor.IReadOnlyModel, token: CancellationToken): Thenable<monaco.languages.DocumentSymbol[]> {
const resource = model.uri;
return wireCancellationToken(token, this._worker(resource).then(worker => worker.findDocumentSymbols(resource.toString())).then(items => {
@ -467,9 +467,11 @@ export class DocumentSymbolAdapter implements monaco.languages.DocumentSymbolPro
}
return items.map(item => ({
name: item.name,
detail: '',
containerName: item.containerName,
kind: toSymbolKind(item.kind),
location: toLocation(item.location)
range: toRange(item.location.range),
selectionRange: toRange(item.location.range)
}));
}));
}