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

<alpha-value> is not recognized on reuse #13716

Open
Serator opened this issue May 20, 2024 · 1 comment
Open

<alpha-value> is not recognized on reuse #13716

Serator opened this issue May 20, 2024 · 1 comment
Assignees

Comments

@Serator
Copy link

Serator commented May 20, 2024

What version of Tailwind CSS are you using?

v3.4.3 (last)

Reproduction URL

https://play.tailwindcss.com/iK3QZJynRz?file=config

Describe your issue

image

Tailwind config

/** @type {import('tailwindcss').Config} */
export default {
  theme: {
    extend: {
      colors: {
                                         ⬇⬇⬇⬇⬇⬇⬇⬇                     ⬇⬇⬇⬇⬇⬇⬇⬇
        primary: 'light-dark(rgb(0 0 0 / <alpha-value>), rgb(255 255 255 / <alpha-value>))',
      }
    },
  },
}

CSS

                              ⬇⬇                     ⬇⬇⬇⬇⬇⬇⬇⬇
color: light-dark(rgb(0 0 0 / 0.5), rgb(255 255 255 / <alpha-value>));

When adding a color to a Tailwind setting with more than one use of <alpha-value> in a single value, only the first occurrence of <alpha-value> is recognized.

More information is available here (сс @olyckne).

barvian added a commit to barvian/tailwindcss that referenced this issue May 24, 2024
thecrypticace added a commit that referenced this issue May 29, 2024
* Fix multiple <alpha-value> in color definitions

Fixes #13716

* Update CHANGELOG.md

* Use `replace` with global regex

---------

Co-authored-by: Jordan Pittman <jordan@cryptica.me>
@thecrypticace thecrypticace self-assigned this May 31, 2024
@thecrypticace
Copy link
Contributor

The fix for this was merged. Will look at tagging a patch release next week 👍

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

No branches or pull requests

2 participants