From 4de879f74e217a26d39a8e22ef3b603d394664df Mon Sep 17 00:00:00 2001 From: Oliver Klee Date: Sun, 9 Feb 2025 17:21:18 +0100 Subject: [PATCH 1/2] [BUGFIX] Fix return type annotation of `Value::isSize()` --- CHANGELOG.md | 1 + src/Value/Size.php | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 38a03088..5eef6627 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -45,6 +45,7 @@ Please also have a look at our ### Fixed +- Fix return type annotation of `Value::isSize()` (#892) - Don't render `rgb` colors with percentage values using hex notation (#803) - Parse `@font-face` `src` property as comma-delimited list (#790) diff --git a/src/Value/Size.php b/src/Value/Size.php index 48ae770b..34b8f2c3 100644 --- a/src/Value/Size.php +++ b/src/Value/Size.php @@ -186,7 +186,7 @@ public function isColorComponent() /** * Returns whether the number stored in this Size really represents a size (as in a length of something on screen). * - * @return false if the unit an angle, a duration, a frequency or the number is a component in a Color object. + * @return bool whether the unit is an angle, a duration, a frequency or the number is a component in a Color object */ public function isSize(): bool { From 2f7e23e32b6bb0cbc9b855eee8225d6be4685129 Mon Sep 17 00:00:00 2001 From: Oliver Klee Date: Sun, 9 Feb 2025 18:44:28 +0100 Subject: [PATCH 2/2] Changes as suggested in code review --- CHANGELOG.md | 1 - src/Value/Size.php | 3 ++- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5eef6627..38a03088 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -45,7 +45,6 @@ Please also have a look at our ### Fixed -- Fix return type annotation of `Value::isSize()` (#892) - Don't render `rgb` colors with percentage values using hex notation (#803) - Parse `@font-face` `src` property as comma-delimited list (#790) diff --git a/src/Value/Size.php b/src/Value/Size.php index 34b8f2c3..ad38de1d 100644 --- a/src/Value/Size.php +++ b/src/Value/Size.php @@ -186,7 +186,8 @@ public function isColorComponent() /** * Returns whether the number stored in this Size really represents a size (as in a length of something on screen). * - * @return bool whether the unit is an angle, a duration, a frequency or the number is a component in a Color object + * Returns `false` if the unit is an angle, a duration, a frequency, or the number is a component in a `Color` + * object. */ public function isSize(): bool {