Properties of objects should not be translated, and therefore are pulled out of the translation strings.
Props ocean90, ramiy, danielbachhuber.
Fixes#38822.
git-svn-id: https://develop.svn.wordpress.org/trunk@39298 602fd350-edb4-49c9-b593-d223f7449a82
iOS disables this feature under the hood, but it also distorts the images – unlike other mobile devices that don't support it. So this adds a check for both `background-attachment: fixed` support or whether it’s an iOS device - passing it adds the class `background-fixed` which is used to add the proper styles.
It also lowers the media query so the parallax-like style is present on a wider range of screens since this bug can be better targeted and avoided. In this way, screens that aren't the offending devices aren't punished merely based on screen size.
Props joemcgill, laurelfulford, helen.
Fixes#38395.
git-svn-id: https://develop.svn.wordpress.org/trunk@39297 602fd350-edb4-49c9-b593-d223f7449a82
Stop presuming IP address are IPv4, instead make the type “ip” to be agnostic of IP version. This fixes requests with ipv6 addresses for comments in core.
Props dd32, schlessera, danielbachhuber.
Fixes#38818.
git-svn-id: https://develop.svn.wordpress.org/trunk@39296 602fd350-edb4-49c9-b593-d223f7449a82
With a few tests for getting / creating comments to reflect core behaviour.
Props timmyc.
git-svn-id: https://develop.svn.wordpress.org/trunk@39295 602fd350-edb4-49c9-b593-d223f7449a82
WordPress has not used the `karma` property internally for the past 8 years. There is no need to expose it in the REST API endpoints. Sites that use `karma` can include it using the `register_rest_field()` function.
Props dd32, danielbachhuber.
Fixes#38821.
git-svn-id: https://develop.svn.wordpress.org/trunk@39292 602fd350-edb4-49c9-b593-d223f7449a82
The `sizes` attribute was calculated incorrectly, resulting in the browser downloading the wrong resource. This filters the attribute to correct that.
Before the filter, the `img` contained:
`sizes="(max-width: 767px) 89vw, (max-width: 1000px) 54vw, (max-width: 1071px) 543px, 580px"`
And after:
`sizes="100vw"`
Props joemcgill, transl8or.
Fixes#38847.
git-svn-id: https://develop.svn.wordpress.org/trunk@39291 602fd350-edb4-49c9-b593-d223f7449a82
Of the default comment_types, only comments are expected to be created via the REST API endpoint. Comments do not have registered types the way that Posts do, so we do not have a method to accurately check permissions for arbitrary comment types.
Props dd32, boonebgorges, rachelbaker.
Fixes#38820.
git-svn-id: https://develop.svn.wordpress.org/trunk@39290 602fd350-edb4-49c9-b593-d223f7449a82
Return a `WP_Error` object for attempts to create a comment without an empty or invalid `post` ID.
Props dd32, jnylen0, rachelbaker.
Fixes#38816.
git-svn-id: https://develop.svn.wordpress.org/trunk@39288 602fd350-edb4-49c9-b593-d223f7449a82
If a user-agent is not explicitly provided in the `author_user_agent` parameter, fallback to the `user_agent` value in the request header.
Props dd32, jnylen0, rachelbaker.
Fixes#38817.
git-svn-id: https://develop.svn.wordpress.org/trunk@39287 602fd350-edb4-49c9-b593-d223f7449a82
This prevents wrapping and looks better, even though there seems to be some space between the other control key characters.
See #38063.
git-svn-id: https://develop.svn.wordpress.org/trunk@39284 602fd350-edb4-49c9-b593-d223f7449a82
Casts `WP_Taxonomy` to an array for passing to the `register_taxonomy` hook. This maintains backward compatibility with the processed arguments used prior to WordPress 4.7.
Fixes#38765.
git-svn-id: https://develop.svn.wordpress.org/trunk@39283 602fd350-edb4-49c9-b593-d223f7449a82
* Set focus before rendering to prevent reload in Firefox.
* Rerender views if they are unloaded.
* Remove timeout added in [29513].
* Fix argument in wp.mce.views.render.
* Empty views on hide. Missed in #36434.
Props gitlost, azaozz, iseulde.
Fixes#38511.
git-svn-id: https://develop.svn.wordpress.org/trunk@39282 602fd350-edb4-49c9-b593-d223f7449a82
This is a follow-up to [39248] that applies a bit more compression to
the default header image in Twenty Seventeen.
Props Presskopp, lukecavanagh.
Fixes#38793.
git-svn-id: https://develop.svn.wordpress.org/trunk@39279 602fd350-edb4-49c9-b593-d223f7449a82
The `SHOW TABLES LIKE` query can be used to search for tables that match a pattern, `wp\_123\_%`, for example. While this isn't the name of an actual table, the `wp_123_` prefix can be used by database drop-ins to direct the query correctly. This change removes the escaping and `%` modifier, to provide this usable prefix.
Props andy, pento.
Fixes#38751.
git-svn-id: https://develop.svn.wordpress.org/trunk@39275 602fd350-edb4-49c9-b593-d223f7449a82
Descendant queries should not inherit the 'offset' and 'number'
parameters of the parent query, or descendants will be missed.
Previously: [38497].
See #37696.
git-svn-id: https://develop.svn.wordpress.org/trunk@39274 602fd350-edb4-49c9-b593-d223f7449a82
Following [39272], this uses the `header_video_settings` filter to modify
the default video header control markup and adds theme specific styles
for the play/pause button.
Props melchoyce, laurelfulford, joemcgill, davidakennedy, bradyvercher.
Fixes#38697.
git-svn-id: https://develop.svn.wordpress.org/trunk@39273 602fd350-edb4-49c9-b593-d223f7449a82
This adds play/pause controls to video headers, along with voice
assistance, using `wp.a11y.speak`, to make custom video headers more
accessible. To make styling the play/pause button easier for themes,
CSS has been omitted from the default implementation.
This also includes a refactor of the `wp.customHeader` code to introduce
a `BaseHandler` class, which can be extended by plugins and themes to modify
or enhance the default video handlers.
Props davidakennedy, afercia, bradyvercher, joemcgill, adamsilverstein, rianrietveld.
Fixes#38678.
git-svn-id: https://develop.svn.wordpress.org/trunk@39272 602fd350-edb4-49c9-b593-d223f7449a82
Some widgets that require more configuration are not included, such as RSS and Custom Menu. Tag Cloud is also not included because fresh sites do not have any tags to display.
Also adds a search widget to a Twenty Seventeen footer widget area.
see #38615.
git-svn-id: https://develop.svn.wordpress.org/trunk@39261 602fd350-edb4-49c9-b593-d223f7449a82
The credits widget from the original commit was a nice test to see the date changing, but isn't really very inspirational. Also, implement it in Twenty Seventeen.
see #38615.
git-svn-id: https://develop.svn.wordpress.org/trunk@39255 602fd350-edb4-49c9-b593-d223f7449a82