• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

MyIntervals / PHP-CSS-Parser / 43925200311
94%

Build:
DEFAULT BRANCH: main
Ran 16 Nov 2026 06:06PM UTC
Jobs 1
Files 55
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

16 Nov 2026 06:05PM UTC coverage: 85.078% (+0.02%) from 85.056%
43925200311

push

github

web-flow
[BUGFIX] Parse identifiers starting with rgb or hsl as identifiers (#1717)

Fixes a parsing where identifiers that start with `rgb` or `hsl` were
treated as colour functions, so the whole declaration was dropped.

`Value::parsePrimitiveValue()` sent any value beginning with `rgb` or
`hsl` to `Color::parse()`. That method requires a `(`, so values such as
`animation-name: rgbshift` or `font-family: hslfont` threw and lenient
mode silently removed the declaration.

The parser now looks ahead and only parses a colour function when the
identifier is followed by `(` (whitespace allowed, case-insensitive).

Performance impact:
| Input | `main` | This PR | Change |
| --- | --- | --- | --- |
| Color-heavy: `rgb()`, `hsla()`, `rgba()` and hex in every block |
354.3 ms | 372.0 ms | +5.0% |
| No `rgb`/`hsl` values: margins, fonts, `calc()` | 364.6 ms | 367.4 ms
| +0.8% |
| Identifiers like `rgbshift`, `hslfont` | 130.9 ms | 156.6 ms | not
comparable (`main` drops these declarations) |

Setup: 4,000 repeated rule blocks per input, median of 7 parses, PHP
8.5.12, Xdebug off.

---------

Co-authored-by: Oliver Klee <github@oliverklee.de>

9 of 11 new or added lines in 1 file covered. (81.82%)

1967 of 2312 relevant lines covered (85.08%)

40.9 hits per line

Uncovered Changes

Lines Coverage ∆ File
2
73.5
1.54% src/Value/Value.php
Jobs
ID Job ID Ran Files Coverage
1 43925200311.1 16 Nov 2026 06:05PM UTC 55
85.08
GitHub Action Run
Source Files on build 43925200311
  • Tree
  • List 55
  • Changed 1
  • Source Changed 1
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #43925200311
  • 9b750bc0 on github
  • Prev Build on main (#43923344282)
  • Next Build on main (#43926936956)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc