* fix `foo-[abc]/[def]` not being handled correctly
This commit does a bit of cleanup, it also ensures that we lookup
`[abc]/[def]` in the `values` first, and if it doesn't exist, then we
start parsing all the values out.
We also ensure that `abc` and `def` are parsed out correctly for the
correct type instead of dropping the rule altogether because we happen
to end up with an `any` rule.
TODO: we should further clean the whole type system because this should
only be used to figure out what type an arbitrary value is and to find
the corresponding plugin and that's it.
One of the fixes is doing a crazy lookup and running a generator, even
though we know it is a lookup value so we should be done with all the
work anyways.
* update changelog
* fix !imp selector not safelisted as valid class
* add tests for !imp selectors in safelist config
* add test to check for invalid variants
* Only check important utilities for patterns that include a `!`
* Update changelog
Co-authored-by: Jordan Pittman <jordan@cryptica.me>
* Pick up changes from files that are both context and content deps
We switched to absolute paths and it broke this revealing a lurking bug. Fun.
* Update changelog
* Update changelog
* fix#9655
* update changelog
* add test for making sure calling variantFn doesn't crash
* make it behave as-if modifiers didn't exist
Co-authored-by: Robin Malfait <malfait.robin@gmail.com>
* remove redundant closing bracket in regex pattern
* test fractional spacing values in theme function
* add test that ensures arbitrary properties are separate
* update changelog
Co-authored-by: Robin Malfait <malfait.robin@gmail.com>
Before we were just checking if the `modifiers` option is `any` or an
object, without actually checking that in case it is an object, the
value actually existed.
* remove unnecessary download links
GitHub already shows them in a table right below it.
* detach `npm run style` from `npm run test`
* decouple lint from test in workflows
Which means that we don't need to do the crazy linking in certain
workflows.
* hoist the `CI` environment variable
* create dedicated `lint` job
The `lint` tests will run against source files and should not be
dependant on a specific node version. Instead of running the `npm run
style` on every node version we use, we can and should only run it once.
* remove `prettier-plugin-tailwindcss`
As long as we use older versions of node/npm where we can't have
ourselves as a dependency, it is a bit of a mess to maintain properly
sorted html in tests.
Let's remove it for now until we have a better solution!
* Record and watch PostCSS dependencies in the CLI
* ensure `changedContent` gets cleared
Otherwise this list gets bigger and bigger, not only that there is a
subtle bug. The moment you save a `.css` file we want to create a new
context and start from scratch. However, since the list was never
cleared, it meant that every subsequent save to *any* file (not only
config / css files) creates a new context...
By clearing the least we should work around this problem.
* add test that verifies an odd bug
The story goes like this:
1. add `underline` to html file
-> css contains `underline` rule
2. add `font-bold` to html file
-> css contains `underline` and `font-bold`
3. remove `underline` from html file
-> css still contains `underline` and `font-bold` for performance reasons
4. Save a css file (! RED FLAG)
-> css contains `font-bold` because we started from scratch
5. add `underline` to html file
-> css contains `underline` and `font-bold`
6. remove `underline` from html file
-> css only contains `font-bold`... (UH OH)
This is because the moment we did step 4, every single save in any file created a new context. Every. Single. Time.
* use a property that doesn't require `autoprefixer`
* update changelog
Co-authored-by: Jordan Pittman <jordan@cryptica.me>