Update theme.lua
authorshaunsingh <71196912+shaunsingh@users.noreply.github.com>
Sun, 16 May 2021 04:50:13 +0000 (00:50 -0400)
committerGitHub <noreply@github.com>
Sun, 16 May 2021 04:50:13 +0000 (00:50 -0400)
lua/nord/theme.lua

index 8a919631c137d75fe901b618cec10c5a92140a6a..a760f84f37fa3302f20ffb8ff3474ae65a9ae5c3 100644 (file)
@@ -49,6 +49,13 @@ theme.loadSyntax = function ()
         markdownH2Delimiter = { fg = nord.red },
         markdownH3Delimiter = { fg = nord.green },
        }
+       
+       syntax.Comment =                {fg = nord.comments}
+       syntax.Conditional =            {fg = nord.purple} -- normal if, then, else, endif, switch, etc.
+       syntax.Keyword =                        {fg = nord.purple} -- normal for, do, while, etc.
+       syntax.Repeat =                         {fg = nord.purple} -- normal any other keyword
+       syntax.Function =               {fg = nord.blue}
+       Identifier =                            {fg = nord.gray}; -- any variable name
 
     return syntax
 
@@ -216,6 +223,18 @@ theme.loadTreeSitter = function ()
         TSLiteral =                 { fg = nord.fg },    -- Literal text.
         TSURI =                     { fg = nord.link },    -- Any URI like a link or email.
     }
+       
+    treesitter.TSComment=                  { fg = nord.comments }
+    treesitter.TSConditional =             { fg = nord.purple }    -- For keywords related to conditionnals.
+    treesitter.TSKeyword =                 { fg = nord.purple } -- For keywords that don't fall in previous categories.
+    treesitter.TSRepeat =                  { fg = nord.purple }    -- For keywords related to loops.
+    treesitter.TSKeywordFunction =         { fg = nord.purple }
+    treesitter.TSFunction =                { fg = nord.blue }    -- For fuction (calls and definitions).
+    treesitter.TSMethod =                  { fg = nord.blue }    -- For method calls and definitions.
+    treesitter.TSFuncBuiltin =             { fg = nord.cyan }
+    treesitter.TSVariable =                { fg = nord.gray } -- Any variable name that does not have another highlight.
+    treesitter.TSVariableBuiltin =         { fg = nord.gray }
+       
     return treesitter
 
 end