mirror of
https://github.com/danbulant/monaco-yaml
synced 2026-07-05 11:00:53 +00:00
Fix mismatched enum types
These enums were annotated as numbers, but they could be more specific.
This commit is contained in:
parent
26b0d6ea96
commit
dd64c96d59
1 changed files with 2 additions and 2 deletions
|
|
@ -19,7 +19,7 @@ export type WorkerAccessor = (...more: Uri[]) => PromiseLike<YAMLWorker>;
|
||||||
|
|
||||||
// --- diagnostics --- ---
|
// --- diagnostics --- ---
|
||||||
|
|
||||||
function toSeverity(lsSeverity: number): MarkerSeverity {
|
function toSeverity(lsSeverity: ls.DiagnosticSeverity): MarkerSeverity {
|
||||||
switch (lsSeverity) {
|
switch (lsSeverity) {
|
||||||
case ls.DiagnosticSeverity.Error:
|
case ls.DiagnosticSeverity.Error:
|
||||||
return MarkerSeverity.Error;
|
return MarkerSeverity.Error;
|
||||||
|
|
@ -176,7 +176,7 @@ function toRange(range: ls.Range): Range {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
function toCompletionItemKind(kind: number): languages.CompletionItemKind {
|
function toCompletionItemKind(kind: languages.CompletionItemKind): languages.CompletionItemKind {
|
||||||
const mItemKind = languages.CompletionItemKind;
|
const mItemKind = languages.CompletionItemKind;
|
||||||
|
|
||||||
switch (kind) {
|
switch (kind) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue