Code Monkey home page Code Monkey logo

Comments (4)

luxus avatar luxus commented on July 26, 2024 1

good feature... i was searching if that is possible

from huez.nvim.

cool-pants avatar cool-pants commented on July 26, 2024 1

Hey there! I had been working on a personal theme manager till I migrated to huez. I was wondering if I could pitch in a proposal for this issue and maybe contribute to this?

Proposed setup

--- huez/init.lua
M.setup = function(user_opts)
---  after setting user_opts
  config.load_theme_configs()
--- Before scheduling and loading current theme
end


--- huez/config.lua
---@class Huez.Config
---@field theme_config_dir? string

M.load_theme_config()
  --- Loads all individual theme configurations set in the directory theme_config_dir
  ---@class Huez.ThemeConf
  ---@field set_theme fun(theme: string):boolean
  local theme_conf = {}

  ---- The below table will contain a mapping from a theme name to the config
  ---@type table<string, Huez.ThemeConf>
  M.themes = {}
end

--- This function will be called instead of vim.cmd.colorscheme to set the theme
---@param theme string
---@return boolean
M.set_theme = function (theme)
  -- Check if set theme is defined for the theme.
  -- If so, call set theme and return response
  -- else call the default vim.cmd.colorscheme with theme to set
end

from huez.nvim.

vague2k avatar vague2k commented on July 26, 2024 1

@cool-pants This seems promising, I like the idea of using a function to set the theme configuration on a per key basis. I'll take a look at it over the weekend

edit: if you'd like to fork it and work on it in the mean you are more than free to do so !

from huez.nvim.

vague2k avatar vague2k commented on July 26, 2024

resolved as of #44

from huez.nvim.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.