Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
CRAP
100.00% covered (success)
100.00%
1 / 1
Declaration
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
100.00% covered (success)
100.00%
1 / 1
 __construct
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
1<?php
2
3declare(strict_types=1);
4
5namespace Phpdftk\Css\Sheet;
6
7use Phpdftk\Css\Value\Value;
8
9/**
10 * A single property-value pair within a style or declaration block.
11 *
12 * The property name is always lower-cased; the value parser handles the
13 * value side. `!important` is captured as a separate flag rather than being
14 * folded into the value, so the cascade can sort by it without re-parsing.
15 */
16final readonly class Declaration
17{
18    public function __construct(
19        public string $property,
20        public Value $value,
21        public bool $important = false,
22    ) {}
23}