Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add public API function to get Nord colors #224

Merged
merged 3 commits into from
May 2, 2021

Conversation

jandamm
Copy link
Contributor

@jandamm jandamm commented Aug 26, 2020

This way a user who wants to use the colors of the Nord theme without having to copy hex-codes from the website.

This way adding/modifying highlight groups could be done like this:

let colors = NordPalette()
execute 'hi MyGroup guifg='.colors.nord3

@arcticicestudio
Copy link
Contributor

Hi @jandamm 👋, thanks for your contribution 👍
This sounds like a great idea. I'll test and review the PR in the near future.

@jandamm
Copy link
Contributor Author

jandamm commented Nov 29, 2020

@arcticicestudio Any update?

Copy link
Contributor

@arcticicestudio arcticicestudio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your patience, the amount of tasks for Nord requires a lot of time.
I've reviewed and tested the function and it works great. Only left one review comment to ensure it is compatible with all colors.

Also please move the function to the bottom of the file and add the following header before it:

"+------------+
"+ Public API +
"+------------+
"+--- Functions ---+

colors/nord.vim Outdated Show resolved Hide resolved
jandamm and others added 2 commits May 1, 2021 22:43
Co-authored-by: Arctic Ice Studio <development@arcticicestudio.com>
@jandamm
Copy link
Contributor Author

jandamm commented May 1, 2021

Sure thing.
Included the bright color and added the public API header 👍

Copy link
Contributor

@arcticicestudio arcticicestudio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks 👍🏼

@arcticicestudio arcticicestudio changed the title Add way to get color palette of nord Add public API function to get Nord colors May 2, 2021
@arcticicestudio arcticicestudio merged commit 5867535 into nordtheme:develop May 2, 2021
@jandamm jandamm deleted the develop branch May 2, 2021 09:48
crispgm pushed a commit to crispgm/nord-vim that referenced this pull request Jun 10, 2021
Implemented the `NordPalette` pubic API function that returns all Nord
colors as dictionary. This allows to use the colors in other Vim scripts
without the need to copy & paste the colors from the documentations or
the Nord Vim theme sources.

Co-authored-by: Arctic Ice Studio <development@arcticicestudio.com>
Co-authored-by: Sven Greb <development@svengreb.de>

Closes nordthemeGH-224
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants