Skip to content

Conversation

@jdujava
Copy link

@jdujava jdujava commented Jul 14, 2024

Description

Document the ability to modify the color palette of a style.

Related Issue(s)

See #595.

@jdujava jdujava changed the title docs: recipe to modify a style docs(readme): recipe to modify a style Jul 15, 2024
@github-actions
Copy link
Contributor

This PR is stale because it has been open 30 days with no activity.

@github-actions github-actions bot added the stale This issue or PR has been inactive for a while label Aug 15, 2024
@jdujava
Copy link
Author

jdujava commented Aug 15, 2024

I think this is still relevant :).

@github-actions github-actions bot removed the stale This issue or PR has been inactive for a while label Aug 16, 2024
@MayRedwood
Copy link

This is not very clear - where, exactly, are we supposed to put that code?

@jdujava
Copy link
Author

jdujava commented Sep 1, 2024

Neighboring examples also don't provide exact instructions on where to put the code. I personally put it in the config function in lazy spec for tokyonight like

config = function(_, opts)                                                       
    local styles = require('tokyonight.colors').styles                           
                                                                                 
    -- change the colors for your new palette here                                          
    ---@type Palette                                                             
    local modified_colors = {                                                    
        bg_darker    = '#1a1a1a',                                                
        ...
    }                                                                            
    -- save as `custom` style (by extending the `storm` style)                                            
    styles.custom = vim.tbl_extend('force', styles.storm --[[@as Palette]], modified_colors)
                                                                                
    require('tokyonight').load(opts) -- load custom style (be sure to have opts.style = 'custom')
                                              
end,                                                                             

If it would be desirable, I have no problem including it in the recipe.

@github-actions
Copy link
Contributor

github-actions bot commented Oct 2, 2024

This PR is stale because it has been open 30 days with no activity.

@github-actions github-actions bot added the stale This issue or PR has been inactive for a while label Oct 2, 2024
@jdujava
Copy link
Author

jdujava commented Oct 2, 2024

Is there a reason for not merging this yet?

@github-actions github-actions bot removed the stale This issue or PR has been inactive for a while label Oct 3, 2024
@github-actions
Copy link
Contributor

github-actions bot commented Nov 3, 2024

This PR is stale because it has been open 30 days with no activity.

@github-actions github-actions bot added the stale This issue or PR has been inactive for a while label Nov 3, 2024
@folke folke added the size/m Medium PR (<50 lines changed) label Oct 19, 2025
@github-actions github-actions bot removed the stale This issue or PR has been inactive for a while label Oct 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/m Medium PR (<50 lines changed)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants