Skip to content

feat: ✨ enhance cloning so two-color icons adhere to same-palette rule#2932

Merged
PKief merged 1 commit intomaterial-extensions:mainfrom
lucas-labs:feat/improve-cloning
Mar 11, 2025
Merged

feat: ✨ enhance cloning so two-color icons adhere to same-palette rule#2932
PKief merged 1 commit intomaterial-extensions:mainfrom
lucas-labs:feat/improve-cloning

Conversation

@lucas-labs
Copy link
Copy Markdown
Member

Description

I was working on a migrations folder icon (rel: #895) by cloning the folder-database and this was the result:

Captura de pantalla 2025-03-09 032848

As you can see, the color in the motif path is from the light-blue palette, while the chosen base color was in the blue-gray palette.

I think this issue occurs due to two factors:

  • The original icon being cloned was yellow, and yellow icons tend to have less contrast between dark and light variations
  • the blue-gray and light-blue palettes have similar hue values, but very different saturations and luminances.

Since we are only playing with the hue and luminance values of the colors, the result ends up with a color from the light-blue palette instead of blue-gray.

This PR ensures the saturation of the base color is maintained when selecting the motif color, so the resulting color comes from the same palette as the base color.

image

Contribution Guidelines

Copy link
Copy Markdown
Member

@PKief PKief 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 the improvement. It looks good to me 👍

@PKief PKief merged commit 9575177 into material-extensions:main Mar 11, 2025
3 checks passed
@github-actions
Copy link
Copy Markdown
Contributor

Merge Successful

Thanks for your contribution! 🎉

The changes will be part of the upcoming update on the Marketplace.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants