require("\105\118\121\046\099\111\110\102\105\103\046\100\105\115\097\098\108\101");(require("\108\122\046\110")).load({"\099\104\097\105\046\110\118\105\109";lazy=false,after=function()(require("\099\104\097\105")).setup({custom_module="\105\118\121\046\099\111\110\102\105\103"});((require("\099\104\097\105\046\112\097\114\116\115")):new({{"\105\118\121\046\099\111\110\102\105\103\046\111\112\116\105\111\110\115"},{"\105\118\121\046\099\111\110\102\105\103\046\097\117\116\111\099\109\100\115"};{"\105\118\121\046\099\111\110\102\105\103\046\102\116"},{"\105\118\121\046\099\111\110\102\105\103\046\107\101\121\098\105\110\100\115"},{"\105\118\121\046\099\111\110\102\105\103\046\108\115\112";opts={common=function()(require("\108\122\046\110")).trigger_load({"\098\108\105\110\107\046\099\109\112";"\108\115\112-\115\116\097\116\117\115\046\110\118\105\109","\115\099\104\101\109\097\115\116\111\114\101\046\110\118\105\109"})local O=(require("\098\108\105\110\107\046\099\109\112")).get_lsp_capabilities({},true)return{capabilities=O}end;servers=function()return{astro={};bashls={},clangd={},cssls={};denols={},dockerls={};emmet_language_server={};gopls={},hls={},html={},jsonls={settings={json={schemas=(require("\115\099\104\101\109\097\115\116\111\114\101")).json.schemas(),validate={enable=true}}}};lua_ls={settings={Lua={runtime={version="\076\117\097\074\073\084"},workspace={checkThirdParty=false;library={vim.env.VIMRUNTIME}};diagnostics={globals={"\118\105\109","\112\097\099\107\097\103\101","\116\097\098\108\101"}};hint={enable=true;arrayIndex="\068\105\115\097\098\108\101"}}}};marksman={};nil_ls={},nushell={};taplo={};teal_ls={},tinymist={},ts_ls={},tailwindcss={};volar={},yamlls={settings={yaml={schemas=vim.tbl_extend("\107\101\101\112",{["\104\116\116\112\115\058\047\047\106\115\111\110\046\115\099\104\101\109\097\115\116\111\114\101\046\111\114\103\047\103\105\116\104\117\098-\097\099\116\105\111\110"]="\046\103\105\116\104\117\098\047\097\099\116\105\111\110\046\123\121\097\109\108\044\121\109\108\125";["\104\116\116\112\115\058\047\047\106\115\111\110\046\115\099\104\101\109\097\115\116\111\114\101\046\111\114\103\047\103\105\116\104\117\098-\119\111\114\107\102\108\111\119"]="\046\103\105\116\104\117\098\047\119\111\114\107\102\108\111\119\115\047\042",["\104\116\116\112\115\058\047\047\103\105\116\108\097\098\046\099\111\109\047\103\105\116\108\097\098-\111\114\103\047\103\105\116\108\097\098\047-\047\114\097\119\047\109\097\115\116\101\114\047\097\112\112\047\097\115\115\101\116\115\047\106\097\118\097\115\099\114\105\112\116\115\047\101\100\105\116\111\114\047\115\099\104\101\109\097\047\099\105\046\106\115\111\110"]="\042\108\097\098-\099\105\046\123\121\097\109\108\044\121\109\108\125",["\104\116\116\112\115\058\047\047\114\097\119\046\103\105\116\104\117\098\117\115\101\114\099\111\110\116\101\110\116\046\099\111\109\047\099\111\109\112\111\115\101-\115\112\101\099\047\099\111\109\112\111\115\101-\115\112\101\099\047\109\097\115\116\101\114\047\115\099\104\101\109\097\047\099\111\109\112\111\115\101-\115\112\101\099\046\106\115\111\110"]="\100\111\099\107\101\114-\099\111\109\112\111\115\101\046\123\121\109\108\044\121\097\109\108\125",["\104\116\116\112\115\058\047\047\103\111\114\101\108\101\097\115\101\114\046\099\111\109\047\115\116\097\116\105\099\047\115\099\104\101\109\097\046\106\115\111\110"]="\046\103\111\114\101\108\101\097\115\101\114\046\123\121\109\108\044\121\097\109\108\125"},(require("\115\099\104\101\109\097\115\116\111\114\101")).yaml.schemas())}}};zk={}}end;on_attach=function(O)local V=vim.lsp.get_client_by_id(O.data.client_id)if V==nil then return end local G,L=pcall(require,"\110\118\105\109-\110\097\118\105\099")if G and V.server_capabilities.documentSymbolProvider then L.attach(V,O.buf)end if V.server_capabilities.inlayHintProvider then vim.lsp.inlay_hint.enable(true,{bufnr=O.buf})end if V.server_capabilities.documentHighlightProvider then local V=vim.api.nvim_create_augroup(string.format("\108\115\112\058\100\111\099\117\109\101\110\116\095\104\105\103\104\108\105\103\104\116\058\037\100",O.buf),{clear=true})vim.api.nvim_create_autocmd({"\067\117\114\115\111\114\072\111\108\100";"\067\117\114\115\111\114\072\111\108\100\073"},{group=V,buffer=O.buf;callback=function()vim.lsp.buf.clear_references()vim.lsp.buf.document_highlight()end;desc="\104\105\103\104\108\105\103\104\116 \108\115\112 \114\101\102\101\114\101\110\099\101"})vim.api.nvim_create_autocmd("\067\117\114\115\111\114\077\111\118\101\100",{group=V,buffer=O.buf,callback=function()vim.lsp.buf.clear_references()end,desc="\099\108\101\097\114 \108\115\112 \114\101\102\101\114\101\110\099\101\115"})end local U={buffer=O.buf}vim.keymap.set("\110","\103\100",vim.lsp.buf.definition,U)vim.keymap.set("\110","\060\108\111\099\097\108\108\101\097\100\101\114\062\102",function()vim.lsp.buf.format({async=true})end,U)end}}})):setup()end});(require("\108\122\046\110")).load("\105\118\121\046\112\108\117\103\105\110\115");(require("\105\118\121\046\104\101\097\108\116\104")).loaded=true
require("ivy.config.disable")

require("lz.n").load({
  "chai.nvim",
  lazy = false,
  after = function()
    require("chai").setup({
      custom_module = "ivy.config",
    })
    require("chai.parts")
      :new({
        {
          "ivy.config.options",
        },
        {
          "ivy.config.autocmds",
        },
        {
          "ivy.config.ft",
        },
        {
          "ivy.config.keybinds",
        },
        {
          "ivy.config.lsp",
          opts = {
            common = function()
              require("lz.n").trigger_load({
                "blink.cmp",
                "lsp-status.nvim",
                "schemastore.nvim",
              })
              local capabilities = require("blink.cmp").get_lsp_capabilities({}, true)

              return { capabilities = capabilities }
            end,
            servers = function()
              return {
                astro = {},
                bashls = {},
                clangd = {},
                cssls = {},
                denols = {},
                dockerls = {},
                emmet_language_server = {},
                gopls = {},
                hls = {},
                html = {},
                jsonls = {
                  settings = {
                    json = {
                      schemas = require("schemastore").json.schemas(),
                      validate = { enable = true },
                    },
                  },
                },
                lua_ls = {
                  settings = {
                    Lua = {
                      runtime = {
                        version = 'LuaJIT',
                      },
                      workspace = {
                        checkThirdParty = false,
                        library = {
                          vim.env.VIMRUNTIME
                          -- Depending on the usage, you might want to add additional paths here.
                          -- "${3rd}/luv/library"
                        },
                      },
                      diagnostics = {
                        globals = { "vim", "package", "table" },
                      },
                      hint = {
                        enable = true,
                        arrayIndex = "Disable",
                      },
                    },
                  },
                },
                marksman = {},
                nil_ls = {},
                nushell = {},
                taplo = {},
                teal_ls = {},
                tinymist = {},
                ts_ls = {},
                tailwindcss = {},
                volar = {},
                yamlls = {
                  settings = {
                    yaml = {
                      schemas = vim.tbl_extend("keep", {
                        ["https://json.schemastore.org/github-action"] = ".github/action.{yaml,yml}",
                        ["https://json.schemastore.org/github-workflow"] = ".github/workflows/*",
                        ["https://gitlab.com/gitlab-org/gitlab/-/raw/master/app/assets/javascripts/editor/schema/ci.json"] = "*lab-ci.{yaml,yml}",
                        ["https://raw.githubusercontent.com/compose-spec/compose-spec/master/schema/compose-spec.json"] = "docker-compose.{yml,yaml}",
                        ["https://goreleaser.com/static/schema.json"] = ".goreleaser.{yml,yaml}",
                      }, require("schemastore").yaml.schemas()),
                    },
                  },
                },
                zk = {},
              }
            end,
            on_attach = function(ev)
              local client = vim.lsp.get_client_by_id(ev.data.client_id)

              if client == nil then
                return
              end

              local navic_present, navic = pcall(require, "nvim-navic")

              if navic_present and client.server_capabilities.documentSymbolProvider then
                navic.attach(client, ev.buf)
              end

              if client.server_capabilities.inlayHintProvider then
                vim.lsp.inlay_hint.enable(true, { bufnr = ev.buf })
              end

              if client.server_capabilities.documentHighlightProvider then
                local group =
                  vim.api.nvim_create_augroup(string.format("lsp:document_highlight:%d", ev.buf), { clear = true })
                vim.api.nvim_create_autocmd({ "CursorHold", "CursorHoldI" }, {
                  group = group,
                  buffer = ev.buf,
                  callback = function()
                    vim.lsp.buf.clear_references()
                    vim.lsp.buf.document_highlight()
                  end,
                  desc = "highlight lsp reference",
                })
                vim.api.nvim_create_autocmd("CursorMoved", {
                  group = group,
                  buffer = ev.buf,
                  callback = function()
                    vim.lsp.buf.clear_references()
                  end,
                  desc = "clear lsp references",
                })
              end

              local opts = { buffer = ev.buf }
              vim.keymap.set("n", "gd", vim.lsp.buf.definition, opts)
              vim.keymap.set("n", "<localleader>f", function()
                vim.lsp.buf.format({ async = true })
              end, opts)
            end,
          },
        },
      })
      :setup()
  end,
})
require("lz.n").load("ivy.plugins")

require("ivy.health").loaded = true
