diff --git a/lua/laravel/config/default.lua b/lua/laravel/config/default.lua index b7a5802..5e9878f 100644 --- a/lua/laravel/config/default.lua +++ b/lua/laravel/config/default.lua @@ -1,3 +1,22 @@ +---@class NullLsFeature +---@field enable boolean + +---@class RouteInfoFeature +---@field enable boolean +---@field position string + +---@class LaravelFeatures +---@field null_ls NullLsFeature +---@field route_info RouteInfoFeature + +---@class LaravelOptions +---@field lsp_server string +---@field register_user_commands boolean +---@field features LaravelFeatures +---@field ui LaravelOptionsUI +---@field commands_options table +---@field environments LaravelOptionsEnvironments +---@field user_commands table return { lsp_server = "phpactor", register_user_commands = true, diff --git a/lua/laravel/config/environments.lua b/lua/laravel/config/environments.lua index 78c6724..c1b0922 100644 --- a/lua/laravel/config/environments.lua +++ b/lua/laravel/config/environments.lua @@ -1,3 +1,16 @@ +---@class EnvironmentCondition +---@field file_exists string[] + +---@class LaravelEnvironmentConfig +---@field name string +---@field condition EnvironmentCondition +---@field commands table + +---@class LaravelOptionsEnvironments +---@field env_variable string +---@field auto_dicover boolean +---@field default string +---@field definitions LaravelEnvironmentConfig[] return { env_variable = "NVIM_LARAVEL_ENV", auto_dicover = true, diff --git a/lua/laravel/config/init.lua b/lua/laravel/config/init.lua index aaa6fc3..32721dc 100644 --- a/lua/laravel/config/init.lua +++ b/lua/laravel/config/init.lua @@ -1,6 +1,6 @@ local M = {} ----@class LaravelOptions +---@type LaravelOptions M.defaults = require "laravel.config.default" --- @type LaravelOptions diff --git a/lua/laravel/config/ui.lua b/lua/laravel/config/ui.lua index d8bc1f8..5194b0b 100644 --- a/lua/laravel/config/ui.lua +++ b/lua/laravel/config/ui.lua @@ -1,3 +1,18 @@ +---@class NuiOptions +---@field enter boolean +---@field relative string +---@field position string|table +---@field size string|table +---@field buf_options table +---@field win_options table + +---@class LaravelOptionsUINui +---@field split NuiOptions +---@field popup NuiOptions + +---@class LaravelOptionsUI +---@field default string +---@field nui_opts LaravelOptionsUINui return { default = "split", nui_opts = {