A Neovim plugin enabling you to solve LeetCode problems.
| 1 | ---@alias lc.lang |
| 2 | ---| "cpp" |
| 3 | ---| "java" |
| 4 | ---| "python" |
| 5 | ---| "python3" |
| 6 | ---| "c" |
| 7 | ---| "csharp" |
| 8 | ---| "javascript" |
| 9 | ---| "typescript" |
| 10 | ---| "php" |
| 11 | ---| "swift" |
| 12 | ---| "kotlin" |
| 13 | ---| "dart" |
| 14 | ---| "golang" |
| 15 | ---| "ruby" |
| 16 | ---| "scala" |
| 17 | ---| "rust" |
| 18 | ---| "racket" |
| 19 | ---| "erlang" |
| 20 | ---| "elixir" |
| 21 | ---| "bash" |
| 22 | ---| "html" |
| 23 | ---| "pythonml" |
| 24 | ---| "react" |
| 25 | ---| "vanillajs" |
| 26 | |
| 27 | ---@alias lc.sql |
| 28 | ---| "pythondata" |
| 29 | ---| "mysql" |
| 30 | ---| "mssql" |
| 31 | ---| "oraclesql" |
| 32 | ---| "postgresql" |
| 33 | |
| 34 | ---@alias lc.domain |
| 35 | ---| "com" |
| 36 | ---| "cn" |
| 37 | |
| 38 | ---@class lc.UserConfig |
| 39 | local M = { |
| 40 | ---@type lc.domain |
| 41 | domain = "com", -- For now "com" is the only one supported |
| 42 | |
| 43 | ---@type string |
| 44 | arg = "leetcode.nvim", |
| 45 | |
| 46 | ---@type lc.lang |
| 47 | lang = "cpp", |
| 48 | |
| 49 | ---@type lc.sql |
| 50 | sql = "mysql", |
| 51 | |
| 52 | ---@type string |
| 53 | directory = vim.fn.stdpath("data") .. "/leetcode/", |
| 54 | |
| 55 | ---@type boolean |
| 56 | logging = true, |
| 57 | |
| 58 | console = { |
| 59 | open_on_runcode = false, ---@type boolean |
| 60 | |
| 61 | dir = "row", ---@type "col" | "row" |
| 62 | |
| 63 | size = { |
| 64 | width = "90%", ---@type string | integer |
| 65 | height = "75%", ---@type string | integer |
| 66 | }, |
| 67 | |
| 68 | result = { |
| 69 | size = "60%", ---@type string | integer |
| 70 | }, |
| 71 | |
| 72 | testcase = { |
| 73 | virt_text = true, ---@type boolean |
| 74 | |
| 75 | size = "40%", ---@type string | integer |
| 76 | }, |
| 77 | }, |
| 78 | |
| 79 | description = { |
| 80 | position = "left", ---@type "top" | "right" | "bottom" | "left" |
| 81 | |
| 82 | width = "40%", ---@type string | integer |
| 83 | }, |
| 84 | } |
| 85 | |
| 86 | return M |