@@ -30855,6 +30855,7 @@ public function __construct(array $settings = array())
3085530855 * Class representing a list of block instances.
3085630856 *
3085730857 * @since 5.5.0
30858+ * @phpstan-implements ArrayAccess<int, WP_Block>
3085830859 */
3085930860 #[\AllowDynamicProperties]
3086030861 class WP_Block_List implements \Iterator, \ArrayAccess, \Countable
@@ -30907,6 +30908,8 @@ public function __construct($blocks, $available_context = array(), $registry = \
3090730908 *
3090830909 * @param string $index Index of block to check.
3090930910 * @return bool Whether block exists.
30911+ * @phpstan-param int $offset
30912+ * @phpstan-return bool
3091030913 */
3091130914 #[\ReturnTypeWillChange]
3091230915 public function offsetExists($index)
@@ -30921,6 +30924,8 @@ public function offsetExists($index)
3092130924 *
3092230925 * @param string $index Index of block value to retrieve.
3092330926 * @return mixed|null Block value if exists, or null.
30927+ * @phpstan-param int $offset
30928+ * @phpstan-return WP_Block|null
3092430929 */
3092530930 #[\ReturnTypeWillChange]
3092630931 public function offsetGet($index)
@@ -30935,6 +30940,8 @@ public function offsetGet($index)
3093530940 *
3093630941 * @param string $index Index of block value to set.
3093730942 * @param mixed $value Block value.
30943+ * @phpstan-param int|null $offset
30944+ * @phpstan-return void
3093830945 */
3093930946 #[\ReturnTypeWillChange]
3094030947 public function offsetSet($index, $value)
@@ -30948,6 +30955,8 @@ public function offsetSet($index, $value)
3094830955 * @link https://www.php.net/manual/en/arrayaccess.offsetunset.php
3094930956 *
3095030957 * @param string $index Index of block value to unset.
30958+ * @phpstan-param int $offset
30959+ * @phpstan-return void
3095130960 */
3095230961 #[\ReturnTypeWillChange]
3095330962 public function offsetUnset($index)
@@ -51815,6 +51824,7 @@ public function set_spacing_sizes()
5181551824 * @package WordPress
5181651825 * @subpackage Theme
5181751826 * @since 3.4.0
51827+ * @phpstan-type ThemeKey 'Name'|'Version'|'Status'|'Title'|'Author'|'Author Name'|'Author URI'|'Description'|'Template'|'Stylesheet'|'Template Files'|'Stylesheet Files'|'Template Dir'|'Stylesheet Dir'|'Screenshot'|'Tags'|'Theme Root'|'Theme Root URI'|'Parent Theme'
5181851828 */
5181951829 #[\AllowDynamicProperties]
5182051830 final class WP_Theme implements \ArrayAccess
@@ -51904,6 +51914,7 @@ public function offsetUnset($offset)
5190451914 *
5190551915 * @param mixed $offset
5190651916 * @return bool
51917+ * @phpstan-return ($offset is ThemeKey ? true : false)
5190751918 */
5190851919 #[\ReturnTypeWillChange]
5190951920 public function offsetExists($offset)
@@ -51923,6 +51934,7 @@ public function offsetExists($offset)
5192351934 *
5192451935 * @param mixed $offset
5192551936 * @return mixed
51937+ * @phpstan-return ($offset is ThemeKey ? mixed : null)
5192651938 */
5192751939 #[\ReturnTypeWillChange]
5192851940 public function offsetGet($offset)
@@ -62032,6 +62044,8 @@ public function merge_with(&$other)
6203262044 * @since 4.4.0
6203362045 *
6203462046 * @link https://www.php.net/manual/en/class.arrayaccess.php
62047+ * @phpstan-template T of array
62048+ * @phpstan-implements ArrayAccess<key-of<T>, value-of<T>>
6203562049 */
6203662050 #[\AllowDynamicProperties]
6203762051 class WP_REST_Request implements \ArrayAccess
@@ -62565,6 +62579,8 @@ public function has_valid_params()
6256562579 *
6256662580 * @param string $offset Parameter name.
6256762581 * @return bool Whether the parameter is set.
62582+ * @phpstan-param @param key-of<T> $offset
62583+ * @phpstan-return bool
6256862584 */
6256962585 #[\ReturnTypeWillChange]
6257062586 public function offsetExists($offset)
@@ -62577,6 +62593,9 @@ public function offsetExists($offset)
6257762593 *
6257862594 * @param string $offset Parameter name.
6257962595 * @return mixed|null Value if set, null otherwise.
62596+ * @phpstan-template TOffset of key-of<T>
62597+ * @phpstan-param TOffset $offset
62598+ * @phpstan-return T[TOffset]
6258062599 */
6258162600 #[\ReturnTypeWillChange]
6258262601 public function offsetGet($offset)
@@ -62589,6 +62608,10 @@ public function offsetGet($offset)
6258962608 *
6259062609 * @param string $offset Parameter name.
6259162610 * @param mixed $value Parameter value.
62611+ * @phpstan-template TOffset of key-of<T>
62612+ * @phpstan-param TOffset $offset
62613+ * @phpstan-param T[TOffset] $value
62614+ * @phpstan-return void
6259262615 */
6259362616 #[\ReturnTypeWillChange]
6259462617 public function offsetSet($offset, $value)
@@ -62600,6 +62623,9 @@ public function offsetSet($offset, $value)
6260062623 * @since 4.4.0
6260162624 *
6260262625 * @param string $offset Parameter name.
62626+ * @phpstan-template TOffset of key-of<T>
62627+ * @phpstan-param TOffset $offset
62628+ * @phpstan-return void
6260362629 */
6260462630 #[\ReturnTypeWillChange]
6260562631 public function offsetUnset($offset)
0 commit comments