Skip to content
New issue

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

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

Already on GitHub? # to your account

Compare two layers with opacity #4

Closed
flytoe opened this issue Jan 30, 2020 · 2 comments
Closed

Compare two layers with opacity #4

flytoe opened this issue Jan 30, 2020 · 2 comments
Assignees
Labels
enhancement New feature or request

Comments

@flytoe
Copy link

flytoe commented Jan 30, 2020

I often use opacity values to match colors on buttons. For example a yellow button with a black (0.8) label. This doesn’t work for now because cluse just interprets the color value with full opacity.

@stdk00
Copy link

stdk00 commented Feb 6, 2020

completely agree. a lot of my text styles have transparency, so this is a must-have.

@ygev ygev added the enhancement New feature or request label Apr 1, 2020
@fafrd fafrd closed this as completed in 6fa73df Apr 1, 2020
@fafrd
Copy link
Collaborator

fafrd commented Apr 1, 2020

Partially resolved. Here's what my commit said:

The color contrast calculation now functions correctly when the
foreground is partially transparent.

Also resolves an issue where the fg or bg opacity value was being
overwritten with 100%.

This isn't an ideal fix for a couple reasons-
- the background opacity is not taken into account.
    This is because we haven't figured out a clever way to get the color
    of whatever is behind the background. It's not immediately clear
    what to do given what the sketch api provides.
- the opacity can't be changed from the plugin menu. it's displayed but
  totally static

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants