Allow child classes to use the private methods and constants#38625
Allow child classes to use the private methods and constants#38625
Conversation
|
I guess this needs to be backported to 5.9.1 ideally right? |
Yeah, that's my thinking. Otherwise, we need to copy a lot of things to the |
youknowriad
left a comment
There was a problem hiding this comment.
This looks good to me but It's very hard to know if it's enough or if we're missing anything.
youknowriad
left a comment
There was a problem hiding this comment.
I noticed that there are still a number of private functions and properties, should we change everything to "protected" or are changing only what we need to extend now?
ntsekouras
left a comment
There was a problem hiding this comment.
Thanks @oandregal! LGTM!
| } | ||
|
|
||
| $output = array_intersect_key( $input, array_flip( self::VALID_TOP_LEVEL_KEYS ) ); | ||
| $output = array_intersect_key( $input, array_flip( static::VALID_TOP_LEVEL_KEYS ) ); |
There was a problem hiding this comment.
Thank you for making these changes for the patterns PR ❤️
I think we can be conservative and change what we need for now, unless there is no specific reason at all to keep them as private. |
I'd love if we do that in order to update the patterns PR tomorrow and verify that these are the only needed changes. |
Yeah, these are the only changes needed for that PR. I have already the modifications to the patterns PR locally for testing. I can push them if that's ok. |
|
Follow up with the rest of the changes at #38671 |
…and VALID_TOP_LEVEL_KEYS (#38625)
…classes. This change updates methods visibility from `private` to `protected` and adds late static binding. Original PRs from Gutenberg repository: - WordPress/gutenberg#38625 - WordPress/gutenberg#38671 Props oandregal, Mamaduka, kapilpaul. Fixes #55178. See #55179. git-svn-id: https://develop.svn.wordpress.org/trunk@52744 602fd350-edb4-49c9-b593-d223f7449a82
…classes. This change updates methods visibility from `private` to `protected` and adds late static binding. Original PRs from Gutenberg repository: - WordPress/gutenberg#38625 - WordPress/gutenberg#38671 Props oandregal, Mamaduka, kapilpaul. Fixes #55178. See #55179. Built from https://develop.svn.wordpress.org/trunk@52744 git-svn-id: http://core.svn.wordpress.org/trunk@52333 1a063a9b-81f0-0310-95a4-ce76da25c4cd
…classes. This change updates methods visibility from `private` to `protected` and adds late static binding. Original PRs from Gutenberg repository: - WordPress/gutenberg#38625 - WordPress/gutenberg#38671 Props oandregal, Mamaduka, kapilpaul. Fixes #55178. See #55179. Built from https://develop.svn.wordpress.org/trunk@52744 git-svn-id: https://core.svn.wordpress.org/trunk@52333 1a063a9b-81f0-0310-95a4-ce76da25c4cd
…classes. This change updates methods visibility from `private` to `protected` and adds late static binding. Original PRs from Gutenberg repository: - WordPress/gutenberg#38625 - WordPress/gutenberg#38671 Props oandregal, Mamaduka, kapilpaul. Merges [52744] to the 5.9 branch. Fixes #55178. See #55179. git-svn-id: https://develop.svn.wordpress.org/branches/5.9@52746 602fd350-edb4-49c9-b593-d223f7449a82
…classes. This change updates methods visibility from `private` to `protected` and adds late static binding. Original PRs from Gutenberg repository: - WordPress/gutenberg#38625 - WordPress/gutenberg#38671 Props oandregal, Mamaduka, kapilpaul. Merges [52744] to the 5.9 branch. Fixes #55178. See #55179. Built from https://develop.svn.wordpress.org/branches/5.9@52746 git-svn-id: http://core.svn.wordpress.org/branches/5.9@52335 1a063a9b-81f0-0310-95a4-ce76da25c4cd
…classes. This change updates methods visibility from `private` to `protected` and adds late static binding. Original PRs from Gutenberg repository: - WordPress/gutenberg#38625 - WordPress/gutenberg#38671 Props oandregal, Mamaduka, kapilpaul. Merges [52744] to the 5.9 branch. Fixes #55178. See #55179. Built from https://develop.svn.wordpress.org/branches/5.9@52746 git-svn-id: https://core.svn.wordpress.org/branches/5.9@52335 1a063a9b-81f0-0310-95a4-ce76da25c4cd
…classes. This change updates methods visibility from `private` to `protected` and adds late static binding. Original PRs from Gutenberg repository: - WordPress/gutenberg#38625 - WordPress/gutenberg#38671 Props oandregal, Mamaduka, kapilpaul. Merges [52744] to the 5.9 branch. Fixes #55178. See #55179. Built from https://develop.svn.wordpress.org/branches/5.9@52746
…classes. This change updates methods visibility from `private` to `protected` and adds late static binding. Original PRs from Gutenberg repository: - WordPress/gutenberg#38625 - WordPress/gutenberg#38671 Props oandregal, Mamaduka, kapilpaul. Merges [52744] to the 5.9 branch. Fixes #55178. See #55179. Built from https://develop.svn.wordpress.org/branches/5.9@52746 git-svn-id: http://core.svn.wordpress.org/branches/5.9@52335 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This PR allows #37140 to override the
WP_Theme_JSON_Resolver_Gutenbergclass and theVALID_TOP_LEVEL_SETTINGSfor this #38323