Skip to content
This repository was archived by the owner on Nov 16, 2024. It is now read-only.

Add ability to cache user color choices based on config #30

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

YoofiBP
Copy link

@YoofiBP YoofiBP commented Nov 13, 2023

Hey @flaming-cl , sorry for the absence. I am resubmitting a PR to allow caching user color choices based on config as I tried ot do many months ago. I would like to address/seek some clarification from your final comment on #11 before the PR was closed.

The plugin will allow users to specify if they want the color caching to be enabled and the number of colors they want in their cache using allow allowUserCachedColors and numberOfUserCachedColors respectively. These colors will be merged with the colorCollection allowing the user to have both. When the max cache size, obtained from numberOfUserCachedColors in the config, is reached, only the cached colors are modified with the most resent placed at the top. In this way the replacement behavior is fairly predictable for users. Do let me know if you have any unanswered concerns.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant