Commit cedd54f
authored
Fix variants with
This PR fixes an issue where if you use a number with a decimal in a
variant then it wasn't picked up correctly.
E.g.:
```
<div class="2xl:flex 1.5xl:flex"></div>
^^^^^^^^ Picked up
^^^^^^^^^^ Not picket up
```
This PR fixes that behavior by applying the same rules for utilities
where a `.` is valid if it is surrounded by numbers.
# Test plan
1. Added test to ensure this is picked up
2. Existing tests pass
3. Ran the extractor on a real example with the following results:
| Before | After |
| --- | --- |
| <img width="821" alt="image"
src="https://github.com/user-attachments/assets/a77ed5e4-6848-4fe3-8cbf-cf61ff8db41d"
/> | <img width="821" alt="image"
src="https://github.com/user-attachments/assets/61aca66a-e38d-4b61-bf86-e6286a89a3d9"
/> |
They are crossed out just because it's not a default value we know in
the system, but you can see that the `1.` part is also extracted now.
Fixes: #17148<digit>.</digit> are extracted correctly (#17153)1 parent 215f4f3 commit cedd54f
2 files changed
Lines changed: 19 additions & 12 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
24 | 25 | | |
25 | 26 | | |
26 | 27 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
235 | 235 | | |
236 | 236 | | |
237 | 237 | | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
238 | 254 | | |
239 | 255 | | |
240 | 256 | | |
| |||
325 | 341 | | |
326 | 342 | | |
327 | 343 | | |
328 | | - | |
329 | | - | |
330 | | - | |
331 | 344 | | |
332 | 345 | | |
333 | 346 | | |
334 | 347 | | |
335 | 348 | | |
336 | 349 | | |
337 | | - | |
338 | | - | |
339 | | - | |
340 | 350 | | |
341 | 351 | | |
342 | 352 | | |
343 | | - | |
344 | | - | |
345 | | - | |
346 | 353 | | |
347 | 354 | | |
348 | 355 | | |
| |||
352 | 359 | | |
353 | 360 | | |
354 | 361 | | |
355 | | - | |
356 | | - | |
357 | | - | |
358 | 362 | | |
359 | 363 | | |
360 | 364 | | |
| |||
391 | 395 | | |
392 | 396 | | |
393 | 397 | | |
| 398 | + | |
| 399 | + | |
394 | 400 | | |
395 | 401 | | |
396 | 402 | | |
| |||
0 commit comments