User: rednesto Date: 28 Sep 24 15:53 Revision: 864ed93a66e62dc15b3867349011fa52c5f028ce Summary: Show mods.toml value type on key completion TeamCity URL: https://ci.mcdev.io/viewModification.html?tab=vcsModificationFiles&modId=9713&personal=false Index: src/main/kotlin/toml/platform/forge/completion/ModsTomlCompletionContributor.kt =================================================================== --- src/main/kotlin/toml/platform/forge/completion/ModsTomlCompletionContributor.kt (revision eaf47abe7cdeedd35f4e5ebdccd7a72f615a4f6f) +++ src/main/kotlin/toml/platform/forge/completion/ModsTomlCompletionContributor.kt (revision 864ed93a66e62dc15b3867349011fa52c5f028ce) @@ -126,8 +126,13 @@ result.addAllElements( variants.map { entry -> - LookupElementBuilder.create(entry, entry.key).withInsertHandler(TomlKeyInsertionHandler(keyValue)) + var lookup = LookupElementBuilder.create(entry, entry.key) + .withInsertHandler(TomlKeyInsertionHandler(keyValue)) + if (entry.type != null) { + lookup = lookup.withTypeText(entry.type.presentableName) - } + } + lookup + } ) } }