diff --git a/lua/care/menu/init.lua b/lua/care/menu/init.lua index dd24eeb..9c42422 100644 --- a/lua/care/menu/init.lua +++ b/lua/care/menu/init.lua @@ -152,7 +152,7 @@ Menu.draw_docs = require("care.utils.async").throttle(function(self, entry) entry.source.source:resolve_item(entry.completion_item, function(resolved_item) entry.completion_item = resolved_item -- TODO: perhaps better solution for this?, e.g. cancel callback? - -- Required to not run into issues when closing immediatelly after selection + -- Required to not run into issues when closing immediately after selection if not self.menu_window:is_open() then return end diff --git a/lua/care/types/config.lua b/lua/care/types/config.lua index 11d29c9..b94a341 100644 --- a/lua/care/types/config.lua +++ b/lua/care/types/config.lua @@ -75,7 +75,7 @@ --- Values of up to about 1000 should also not cause performance issue. ---@field max_view_entries? integer ---- # Ui Configuration +--- # UI Configuration --- This is used to configure the whole UI of care. ---@class care.config.ui --- Configuration of the completion menu of care.nvim @@ -122,7 +122,7 @@ --- alignment of each section. --- --- For example you want to have the label of an entry in a red highlight and an ---- icon in a entry-kind specific color left aligned first and then the source of +--- icon in an entry-kind specific color left aligned first and then the source of --- the entry right aligned in blue. You could do that like this: --- --- ```lua diff --git a/lua/care/types/context.lua b/lua/care/types/context.lua index 10ebf7a..e474902 100644 --- a/lua/care/types/context.lua +++ b/lua/care/types/context.lua @@ -25,7 +25,7 @@ --- The complete line on which the cursor was when the context was created. ---@field line string --- The line before the cursor. This is mostly important to be correct in insert ---- mode. In normal mode the character on which the cursor is is not included. +--- mode. In normal mode the character on which the cursor is not included. ---@field line_before_cursor string --- A cursor position diff --git a/lua/care/types/core.lua b/lua/care/types/core.lua index d7765ac..c39f72b 100644 --- a/lua/care/types/core.lua +++ b/lua/care/types/core.lua @@ -35,5 +35,5 @@ --- the last time. This is used to determine when to reopen the completion window. ---@field last_opened_at integer --- Boolean to indicate if care is currently completing. This is used to avoid ---- compmleting and sorting on the same keystroke. +--- completing and sorting on the same keystroke. ---@field completing boolean diff --git a/lua/care/types/preset_utils.lua b/lua/care/types/preset_utils.lua index 2750314..009e951 100644 --- a/lua/care/types/preset_utils.lua +++ b/lua/care/types/preset_utils.lua @@ -1,6 +1,6 @@ --- This module contains lower level utilities for the presets and the preset components. ---@class care.preset_utils ---- This function can be used to get a function to label the entries with shortscuts as [described +--- This function can be used to get a function to label the entries with shortcuts as [described --- here](/configuration_recipes#labels-and-shortcuts). ---@field label_entries fun(labels: string[]): fun(_,data: care.format_data): string --- With this function you can get a color if the entry is a color and the hex color code is available in the @@ -8,11 +8,11 @@ ---@field get_color fun(entry: care.entry): string? --- This function allows to get a highlight group for a certain hex color code. This is useful because like that the --- user doesn't have to constantly create new highlight groups to apply a hex value to a certain thing. The ---- highlight group will have the hex value as foregroung color. +--- highlight group will have the hex value as foreground color. ---@field get_highlight_for_hex fun(hex: string): string --- With this function you can get the kind highlight group for a specific entry. The style can either be foreground --- or blended. ---@field kind_highlight fun(entry: care.entry, style: "fg"|"blended"): string ---- Gets the label detail if provided by the language serve. +--- Gets the label detail if provided by the language server. --- This is equivalent to the `vim_item.menu` from nvim-cmp ---@field get_label_detail fun(entry: care.entry): string diff --git a/lua/care/types/source.lua b/lua/care/types/source.lua index 9ad2b7f..6bff63a 100644 --- a/lua/care/types/source.lua +++ b/lua/care/types/source.lua @@ -1,4 +1,4 @@ ---- The sources are used to get get completions for care.nvim. +--- The sources are used to get completions for care.nvim. ---@class care.source --- The `name` field is used for configuring the source. It should just contain characters, `_`, and `-`. ---@field name string diff --git a/lua/care/utils/init.lua b/lua/care/utils/init.lua index b34c86f..0a5b723 100644 --- a/lua/care/utils/init.lua +++ b/lua/care/utils/init.lua @@ -1,6 +1,6 @@ local utils = {} ---- Gets lenght of longest string of an array +--- Gets length of longest string of an array ---@param lines table ---@return number function utils.longest(lines)