Commit Graph

38439 Commits

Author SHA1 Message Date
Andrew Ozz 2325faeb96 TinyMCE: do not force-load external plugins, not needed any more and may cause issues.
Fixes #44330.

git-svn-id: https://develop.svn.wordpress.org/trunk@43337 602fd350-edb4-49c9-b593-d223f7449a82
2018-06-08 09:32:35 +00:00
Andrew Ozz a56df22d91 TinyMCE: prevent creation of paragraphs from multiple HTML comments when `wpautop` is disabled.
Fixes #44308.

git-svn-id: https://develop.svn.wordpress.org/trunk@43336 602fd350-edb4-49c9-b593-d223f7449a82
2018-06-08 08:58:51 +00:00
Jeremy Felt 8d9cd406fb Build/Test Tools: Avoid running full PHPUnit test suite for every PHP file change.
Use `grunt watch --phpunit --group={testgroup}` to start `grunt watch` with a specific test group so that PHP file changes trigger a limited number of tests.

Props jeremyfelt, birgire for testing.
Fixes #44240.


git-svn-id: https://develop.svn.wordpress.org/trunk@43335 602fd350-edb4-49c9-b593-d223f7449a82
2018-06-08 04:40:18 +00:00
Anton Timmermans a14e4f1c86 Docs: Improve JSDoc for `language-chooser.js`.
Props ireneyoast, manuelaugustin.
Fixes #43950.


git-svn-id: https://develop.svn.wordpress.org/trunk@43334 602fd350-edb4-49c9-b593-d223f7449a82
2018-06-07 15:07:31 +00:00
Anton Timmermans 8a9bf2a08b Docs: Improve JSDoc for `zxcvbn-async.js`.
Props manuelaugustin, igorsch, LisanneKluitmans.
Fixes 43948.


git-svn-id: https://develop.svn.wordpress.org/trunk@43333 602fd350-edb4-49c9-b593-d223f7449a82
2018-06-07 14:51:02 +00:00
Anton Timmermans a65ad8a247 Docs: Improve JSDoc for `admin-bar.js`.
Props manuelaugustin, terwdan, sjardo, LisanneKluitmans.
Fixes #43871.


git-svn-id: https://develop.svn.wordpress.org/trunk@43332 602fd350-edb4-49c9-b593-d223f7449a82
2018-06-07 14:39:43 +00:00
Sergey Biryukov f4580c122b Users: In `wp_validate_user_request_key()`, properly return the `WP_Error` object in case the confirmation email has expired.
Props itowhid06.
Fixes #44298.

git-svn-id: https://develop.svn.wordpress.org/trunk@43331 602fd350-edb4-49c9-b593-d223f7449a82
2018-06-04 13:45:13 +00:00
Sergey Biryukov 88df6476cd Docs: Remove obsolete `$wpdb` global references in `WP_User::__construct()` and `WP_User::for_blog()`.
Props mt8.biz.
Fixes #44295.

git-svn-id: https://develop.svn.wordpress.org/trunk@43330 602fd350-edb4-49c9-b593-d223f7449a82
2018-06-04 13:38:33 +00:00
Gary Pendergast a26c24226c Build Tools: `grunt build` should only copy Core files.
Historically, `grunt build` has copied all files from the `src` directory to the `build` directory. This is usually fine, but can be super slow when there are lots of custom plugins or themes in the `src` directory.

To rectify this, we now only copy Core plugins and themes to `build`.

Props adamsilverstein, pento, johnbillion.
Fixes #44256.



git-svn-id: https://develop.svn.wordpress.org/trunk@43329 602fd350-edb4-49c9-b593-d223f7449a82
2018-06-01 01:28:53 +00:00
Sergey Biryukov ecb3302b45 Build/Test Tools: Replace Codex home page link in "Read more about setting up your local development environment" with a more specific handbook link.
Props abdullahramzan, johnbillion.
Fixes #44228.

git-svn-id: https://develop.svn.wordpress.org/trunk@43328 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-30 14:55:10 +00:00
Andrew Ozz ccecd58f97 Build tools: Grunt:
- Normalize `filepath` in the the `watch` event.
- Throw a warning when `watch` fails to process a file because the destination path cannot be determined.

Fixes #44262.

git-svn-id: https://develop.svn.wordpress.org/trunk@43327 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-29 14:20:44 +00:00
Jeremy Felt 50cd98012e Docs: Document globals in validate_another_blog_signup().
Props mukesh27.
Fixes #43594.


git-svn-id: https://develop.svn.wordpress.org/trunk@43326 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-27 20:06:19 +00:00
Sergey Biryukov b9a3b166e5 Docs: Fix typo in `Services_JSON` DocBlocks.
Props sagarnasit.
Fixes #44244.

git-svn-id: https://develop.svn.wordpress.org/trunk@43325 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-27 19:41:16 +00:00
Jeremy Felt 532d177b65 Built/Test Tools: Increase grunt watch interval on all files.
Significantly reduces Grunt's CPU usage when `grunt watch` is in an idle/watching state.

Props netweb.
Fixes #44241.


git-svn-id: https://develop.svn.wordpress.org/trunk@43324 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-27 18:46:15 +00:00
Andrew Ozz 247eba769e Build tools: Update Grunt to version 1.0.2.
Props iandunn, netweb.
Fixes #42308.

git-svn-id: https://develop.svn.wordpress.org/trunk@43323 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-27 17:02:22 +00:00
Andrew Ozz 4fc1579427 Build tools:
- Remove `check-node-version` from package.json for now. Throws errors.
- Minor fixes to package-lock.json, `http` => `https`.

See #44246.

git-svn-id: https://develop.svn.wordpress.org/trunk@43322 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-27 16:42:34 +00:00
Andrew Ozz 338e951cec Build tools: add `check-node-version` to check required Node.js and npm versions are installed.
Props netweb.
Fixes #44246.

git-svn-id: https://develop.svn.wordpress.org/trunk@43321 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-27 16:07:48 +00:00
Andrew Ozz f26fe4ea9c Build tools: Use npm v6.1.0.
Props netweb.
Fixes #44245.

git-svn-id: https://develop.svn.wordpress.org/trunk@43320 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-27 16:00:45 +00:00
Sergey Biryukov d67826119d Docs: Fix typo in `_walk_bookmarks()` DocBlock.
Props abhijitrakas.
Fixes #44242.

git-svn-id: https://develop.svn.wordpress.org/trunk@43319 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-27 08:35:12 +00:00
Sergey Biryukov 302a2297dd Posts, Post Types: Use `COOKIEPATH` when clearing post password cookie, as that's the path it's created with.
See #44089.

git-svn-id: https://develop.svn.wordpress.org/trunk@43318 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-27 01:32:20 +00:00
Sergey Biryukov daf0333601 Posts, Post Types: Clear post password cookie when logging out.
Props skoldin, subrataemfluence, ianbelanger, johnbillion.
Fixes #44089.

git-svn-id: https://develop.svn.wordpress.org/trunk@43317 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-26 12:42:57 +00:00
John Blackbourn 58a71dc610 Build/Test Tools: Allow the unit test framework to be used without the data directory in place.
Fixes #43982

git-svn-id: https://develop.svn.wordpress.org/trunk@43315 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-25 22:42:11 +00:00
Boone Gorges 39fb88f961 Taxonomy: Improve cache handling when querying for terms using `all_with_object_id`.
When a term query using `fields=all_with_object_id` hits the cache, the
cached `stdClass` objects must be converted to `WP_Term` objects. This
was overlooked when `WP_Term_Query` was refactored to support object
queries in [38667].

Props dlh.
Fixes #44221.

git-svn-id: https://develop.svn.wordpress.org/trunk@43313 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-25 01:22:44 +00:00
Gary Pendergast 53e3a17e6f Tools: Update `wp-cli.yml` to point to the `build` directory.
After [43309], WP-CLI should be running against the `build` directory, not the `src` directory.

Props jpry.
Fixes #44214.



git-svn-id: https://develop.svn.wordpress.org/trunk@43312 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-25 00:14:14 +00:00
John Blackbourn f4fbba188d Build/Test Tools: Roses are red, this fixes stuff.
Update the test infrastructure so that third party plugins, themes, and projects that use the core testing framework continue to operate from the `src` directory and do not require a build step.

Props mboynes, danielbachhuber, schlessera

See #43055


git-svn-id: https://develop.svn.wordpress.org/trunk@43311 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-23 17:54:44 +00:00
Gary Pendergast 386adbb8f8 Following [43309], I need to change one little line,
And delete some left over cruft, only then shall we prevail.
There are some things easily missed, when using Git, which does not persist—
Empty directories, though that didn't derail—
Our Travis-based tests, which now must prevail.
            Quoth Travis CI, “Build did fail.”

See #43055.



git-svn-id: https://develop.svn.wordpress.org/trunk@43310 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-23 11:02:28 +00:00
Gary Pendergast ef37f002ee Once upon a midnight dreary, while I coded, weak and weary,
In many a strange and curious file of forgotten lore—
While I pondered, blaming Nacin, my notifications suddenly awakened,
As of someone quietly DMing;—DMing me, I can’t ignore.
“’Tis some contributor,” I muttered, “DMing me an idea or four—
            Only this and nothing more.”

Ah, distinctly I remember, at WordCamp US, last December;
A mad proposal nearly laid me—down out cold—upon the floor.
Curious, I listened closely;—to a plan I agreed with, mostly—
A way to make our JavaScript—JavaScript which was a chore—
Maintainable, extendable, for the future, is what I saw.
            Guten-ready for evermore.

Open here I switch to Slack, when, with many a patch and hack,
In there stepped Omar, a JavaScript developer hardcore;
Pronouncing all the changes fit; ready now to be commit;
“There’s nothing else for us to do,” DMing me, “It’s done!” he swore—
“No longer random guessing at which file need next be explored—
            Let’s move on, we’re all aboard.”

Moved all together, grouped and managed, in folders all is packaged,
The code had all been cleaned and tidied, important parts moved to the fore,
“Though this change be useful here,” I said, “it is too large, I fear,
We couldn’t manage such a patch, we’ve done nothing like this before—
Tell me where doth go this change, change to make our codebase soar!”
            Quoth Omar, “In WordPress Core.”

Props omarreis for shepherding this significant change.
Props adamsilverstein, aduth, atimmer, dingo_bastard, frank-klein, gziolo, herregroen, jaswrks, jeremyfelt, jipmoors, jorbin, netweb, ocean90, pento, tjnowell, and youknowriad for testing, feedback, discussion, encouragement, commiserations, etc.
I make no apologies for this commit message.
Fixes #43055.



git-svn-id: https://develop.svn.wordpress.org/trunk@43309 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-23 10:04:22 +00:00
Boone Gorges acebda9aa5 Taxonomy: Fix `$object_ids` reference in `WP_Term_Query` parameter documentation.
Props dlh.
Fixes #44200.

git-svn-id: https://develop.svn.wordpress.org/trunk@43308 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-23 02:23:53 +00:00
Sergey Biryukov 879453da2a Docs: Escape the `<!--nextpage-->` page tag in `wp_link_pages()` and `get_the_content()` description for proper display in Developer Reference.
Props grapplerulrich.
See #42505.

git-svn-id: https://develop.svn.wordpress.org/trunk@43307 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-22 18:56:49 +00:00
Sergey Biryukov 67c7c7d74a Docs: Document the `cookies` default comment field added in [42772].
Props desrosj, chetan200891.
See #44125.

git-svn-id: https://develop.svn.wordpress.org/trunk@43304 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-21 13:12:16 +00:00
Sergey Biryukov d612af2e5e Docs: Add missing documentation and duplicate hook references for `wp_privacy_personal_data_export_file`, `wp_privacy_personal_data_exporters`, and `wp_privacy_personal_data_erasers` hooks.
Props birgire.
See #44125.

git-svn-id: https://develop.svn.wordpress.org/trunk@43303 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-21 13:02:55 +00:00
Sergey Biryukov 0e067ab91e Privacy: Correct the error check when creating an export folder in `wp_privacy_generate_personal_data_export_file()`.
`wp_mkdir_p()` returns `false` on error, not a `WP_Error` object.

Props birgire.
Fixes #44158.

git-svn-id: https://develop.svn.wordpress.org/trunk@43299 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-21 11:58:19 +00:00
laurelfulford 186bb7c8a9 Bundled Themes: Bump version numbers and update changelogs for 4.9.6 release
* Also, updates POT files for Twenty Ten and Twenty Eleven.

Props earnjam, laurelfulford.

Fixes #43915.


git-svn-id: https://develop.svn.wordpress.org/trunk@43293 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-17 17:06:12 +00:00
iandunn 238504d36f Tests: Add case for `wp_privacy_delete_old_export_files()`.
Props allendav.
See #43546.


git-svn-id: https://develop.svn.wordpress.org/trunk@43292 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-17 16:38:01 +00:00
Ian Dunn 84211ab4b6 Tests: Add case for `wp_privacy_send_personal_data_export_email()`.
Props birgire.
See #43546.


git-svn-id: https://develop.svn.wordpress.org/trunk@43291 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-16 23:53:38 +00:00
Ian Dunn ac4d875f94 Comments: Escape permalink values on edit screen to prevent XSS.
There doesn't appear to be any way for an attacker to introduce malicious input into the URL, unless a plugin is filtering the URL to add it, but it's better to be safe than sorry.

Props 1naveengiri, joyously.
Fixes #44115.


git-svn-id: https://develop.svn.wordpress.org/trunk@43290 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-16 22:38:20 +00:00
Ian Dunn d488fc7dac Privacy: Require `manage_privacy_options` to edit policy page.
A user is required to have the `manage_privacy_options` capability in order to determine which page is set as the privacy policy (the `wp_page_for_privacy_policy`). Given that, it doesn't make sense to allow users without that capability to edit or delete the page. 

A similar situation exists with the `page_for_posts` and `page_on_front` options, but Editors are allowed to edit those pages. The reason that this situation is different is because it is more likely that an administrator will want to restrict modifications to the privacy policy, than it is that they will want to allow modifications. Modifications to the policy often require specialized knowledge of local laws, and can have implications for compliance with those laws.

Props dlh, desrosj.
Fixes #44079.


git-svn-id: https://develop.svn.wordpress.org/trunk@43286 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-15 20:43:59 +00:00
Ian Dunn 3e3db8af66 Privacy: Rename exports folder to avoid deleting other files.
Previously, personal data exports were stored in `wp-content/uploads/exports`, which is generic enough that it's likely there are existing folders with that name, either created by plugins or manually by administrators. If that folder were reused by Core, then `wp_privacy_delete_old_export_files()` would delete all of the existing files inside it, which is almost certainly not what the site owner wants or expects.

To avoid that, the folder is being renamed to include a specific reference to Core, and a more verbose description of its purpose. With those factored in, it's very unlikely that there will be any conflicts with existing folders.

The `wp_privacy_exports_dir()` and `wp_privacy_exports_url()` functions were introduced to provide a canonical source for the location, and the `wp_privacy_exports_dir` and `wp_privacy_exports_url` filters were introduced to allow plugins to customize it.

Props johnjamesjacoby, allendav.
Fixes #44091.


git-svn-id: https://develop.svn.wordpress.org/trunk@43284 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-15 20:21:37 +00:00
Andrew Ozz ced82abf66 Privacy: use the more compatible `word-break: break-all;`, see [43278].
See #44092.

git-svn-id: https://develop.svn.wordpress.org/trunk@43282 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-15 20:06:39 +00:00
Andrew Ozz 6ab60cb0b6 Privacy: fix styling of the Privacy Settings buttons on mobile/small screens.
Props ianbelanger, azaozz.
Fixes #44093.

git-svn-id: https://develop.svn.wordpress.org/trunk@43279 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-15 19:26:04 +00:00
Andrew Ozz b8810cc225 Privacy: fix styling of the "next steps" buttons on the Export/Erase tools screens when text is long.
Props audrasjb, ianbelanger.
Fixes #44092.

git-svn-id: https://develop.svn.wordpress.org/trunk@43278 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-15 18:58:29 +00:00
Felix Arntz 2c4326cff1 Widgets: Allow basic inline tags in `wp_sidebar_description()`.
The customizer has allowed HTML in sidebar descriptions since adding support for sidebars. This change ensures that basic HTML is also allowed for them in the widgets admin screen.

Fixes #42608.


git-svn-id: https://develop.svn.wordpress.org/trunk@43275 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-15 16:54:12 +00:00
Ian Dunn f822373476 Privacy: Reposition log in policy link to avoid overlapping elements.
Previously, the link used absolute positioning, in order to stick it at the bottom of the page. That was done in order to create visual separation between it and the "action" links, like "Lost Your Password?"

The absolute positioning can cause conflicts in some situations, though. For example, if extra text or error notices are added above the form, then the login link would be positioned on top of other elements.

Switching to relative positioning with extra margins avoids those issues, while maintaining the visual separation between the "action" links and the privacy policy link.

Props imath, melchoyce, desrosj, xkon, iandunn.
Fixes #44046.


git-svn-id: https://develop.svn.wordpress.org/trunk@43274 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-15 16:26:12 +00:00
Andrew Ozz e72d503702 Privacy: only remove the "Suggested text has changed" bubble when an admin visits the Privacy Policy Guide screen.
Fixes #44063.

git-svn-id: https://develop.svn.wordpress.org/trunk@43269 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-14 17:51:04 +00:00
Andrew Ozz cc66df9b5c Privacy: add `wp_page_for_privacy_policy` to `populate_options()`.
Props ocean90.
Fixes #44076.

git-svn-id: https://develop.svn.wordpress.org/trunk@43267 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-14 16:59:46 +00:00
Andrew Ozz d9e0a41c20 Privacy: fix markup for the table of contents on privacy policy guide screen.
Props ocean90, azaozz.
Fixes #44056.

git-svn-id: https://develop.svn.wordpress.org/trunk@43265 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-14 16:45:57 +00:00
Andrew Ozz 3ef1d8a2c9 Privacy: fix the "Privacy Policy Guide updated" message and add a link to the guide.
Props birgire, azaozz.
Fixes #44057.

git-svn-id: https://develop.svn.wordpress.org/trunk@43263 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-14 16:20:53 +00:00
Dominik Schilling (ocean90) 8288241045 Privacy: Remove `is-dismissible` class from notice when privacy info has changed.
The notice isn't dismissible as it only gets removed once you visit the privacy guide, see #44057 and #44063.

Fixes #44065.


git-svn-id: https://develop.svn.wordpress.org/trunk@43261 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-14 15:54:22 +00:00
Dominik Schilling (ocean90) 2865e6f324 Privacy: Don't show privacy feature pointer to new users.
Fixes #44062.

git-svn-id: https://develop.svn.wordpress.org/trunk@43259 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-14 15:49:55 +00:00
John Blackbourn 6449cc7970 Docs: Add missing HTTP methods to the list of those supported.
See #42505


git-svn-id: https://develop.svn.wordpress.org/trunk@43258 602fd350-edb4-49c9-b593-d223f7449a82
2018-05-14 15:22:45 +00:00