diff --git a/provider/hello-world/index.ts b/provider/hello-world/index.ts index 2eda5f85..10bf7019 100644 --- a/provider/hello-world/index.ts +++ b/provider/hello-world/index.ts @@ -4,6 +4,8 @@ import type { AnnotationsResult, ItemsParams, ItemsResult, + MentionsParams, + MentionsResult, MetaParams, MetaResult, Provider, @@ -12,7 +14,7 @@ import type { /** * A demo [OpenCtx](https://openctx.org) provider that annotates every 10th line in every - * file with "✨ Hello, world!". + * file with "✨ Hello, world!" and returns a dummy mention. */ const helloWorld: Provider = { meta(params: MetaParams, settings: ProviderSettings): MetaResult { @@ -25,6 +27,16 @@ const helloWorld: Provider = { } }, + mentions(params: MentionsParams, settings: ProviderSettings): MentionsResult { + return [ + { + title: '✨ Hello, world!', + uri: 'https://openctx.org', + description: 'From OpenCtx', + }, + ] + }, + items(params: ItemsParams, settings: ProviderSettings): ItemsResult { return [ {