@@ -22,7 +22,6 @@ export const createTwoslashInlayProvider = (sandbox: Sandbox) => {
22
22
23
23
const hint = await worker . getQuickInfoAtPosition ( "file://" + model . uri . path , inspectionOff )
24
24
if ( ! hint || ! hint . displayParts ) continue
25
- console . log ( { hint } )
26
25
27
26
const inlay : import ( "monaco-editor" ) . languages . InlayHint = {
28
27
// @ts -ignore
@@ -38,48 +37,3 @@ export const createTwoslashInlayProvider = (sandbox: Sandbox) => {
38
37
}
39
38
return provider
40
39
}
41
-
42
- // class InlayHintsAdapter extends Adapter implements import("monaco-editor").editor.languages.InlayHintsProvider {
43
- // public async provideInlayHints(
44
- // model: import("monaco-editor").ITextModel,
45
- // range: Range,
46
- // token: CancellationToken
47
- // ): Promise<languages.InlayHint[]> {
48
- // const resource = model.uri
49
- // const fileName = resource.toString()
50
- // const start = model.getOffsetAt({
51
- // lineNumber: range.startLineNumber,
52
- // column: range.startColumn,
53
- // })
54
-
55
- // const end = model.getOffsetAt({
56
- // lineNumber: range.endLineNumber,
57
- // column: range.endColumn,
58
- // })
59
- // const worker = await this._worker(resource)
60
- // if (model.isDisposed()) {
61
- // return []
62
- // }
63
-
64
- // const hints = await worker.provideInlayHints(fileName, start, end)
65
-
66
- // return hints.map(hint => {
67
- // return {
68
- // ...hint,
69
- // position: model.getPositionAt(hint.position),
70
- // kind: this._convertHintKind(hint.kind),
71
- // }
72
- // })
73
- // }
74
-
75
- // private _convertHintKind(kind?: ts.InlayHintKind) {
76
- // switch (kind) {
77
- // case "Parameter":
78
- // return languages.InlayHintKind.Parameter
79
- // case "Type":
80
- // return languages.InlayHintKind.Type
81
- // default:
82
- // return languages.InlayHintKind.Other
83
- // }
84
- // }
85
- // }
0 commit comments