diff --git a/CHANGELOG.md b/CHANGELOG.md index 76c5713f..ab465af9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -18,7 +18,7 @@ Please also have a look at our ### Changed -- `Rule\Rule` class is renamed to `Property\Declaration` (#1508) +- `Rule\Rule` class is renamed to `Property\Declaration` (#1508, #1512) - `Rule::setRule()` and `getRule()` are replaced with `setPropertyName()` and `getPropertyName()` (#1506) - `Selector` is now represented as a sequence of `Selector\Component` objects diff --git a/src/CSSList/CSSBlockList.php b/src/CSSList/CSSBlockList.php index 122ac5d1..574bdaa3 100644 --- a/src/CSSList/CSSBlockList.php +++ b/src/CSSList/CSSBlockList.php @@ -5,8 +5,8 @@ namespace Sabberworm\CSS\CSSList; use Sabberworm\CSS\CSSElement; +use Sabberworm\CSS\Property\Declaration; use Sabberworm\CSS\Property\Selector; -use Sabberworm\CSS\Rule\Rule; use Sabberworm\CSS\RuleSet\DeclarationBlock; use Sabberworm\CSS\RuleSet\RuleContainer; use Sabberworm\CSS\RuleSet\RuleSet; @@ -65,7 +65,7 @@ public function getAllRuleSets(): array } /** - * Returns all `Value` objects found recursively in `Rule`s in the tree. + * Returns all `Value` objects found recursively in `Declaration`s in the tree. * * @param CSSElement|null $element * This is the `CSSList` or `RuleSet` to start the search from (defaults to the whole document). @@ -105,7 +105,7 @@ public function getAllValues( $this->getAllValues($rule, $ruleSearchPattern, $searchInFunctionArguments) ); } - } elseif ($element instanceof Rule) { + } elseif ($element instanceof Declaration) { $value = $element->getValue(); // `string` values are discarded. if ($value instanceof CSSElement) {