Commit Graph

35669 Commits

Author SHA1 Message Date
Rachel Baker 6413c1efce REST API: Delete temporary files during teardown of `WP_Test_REST_Attachments_Controller`.
Props jnylen0.
Fixes #38574.

git-svn-id: https://develop.svn.wordpress.org/trunk@39041 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 23:31:06 +00:00
Dominik Schilling (ocean90) f4b61df0e4 I18N: Don't use `get_user_option()` for retrieving user's language.
`get_user_option()` checks for both option types, site and network. Since `locale` is only a network option we can directly access the field via `WP_User`s magic getter.

Props johnjamesjacoby.
Fixes #38578.

git-svn-id: https://develop.svn.wordpress.org/trunk@39040 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 22:25:34 +00:00
Dominik Schilling (ocean90) 7d378f82d0 I18N: Use correct value for the `for` attribute of the user language setting label.
Props johnjamesjacoby.
Fixes #38576.

git-svn-id: https://develop.svn.wordpress.org/trunk@39039 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 21:57:17 +00:00
Weston Ruter 4de2e30bb4 Customize: Prevent auto-draft post/page stubs from being saved with empty slugs or published with non-unique slugs.
* Allow `WP_Customize_Nav_Menus::insert_auto_draft_post()` to take full post array to pass to `wp_insert_post()`, except for `post_status`. Require `post_title`. 
* Ensure empty `post_name` gets explicitly set to slugified `post_title`.
* Explicitly allow only `post_type` and `post_title` params in `WP_Customize_Nav_Menus::ajax_insert_auto_draft_post()`.
* Use `wp_update_post()` instead of `wp_publish_post()` to ensure unique slugs are assigned to published auto-draft posts.
* Re-use `WP_Customize_Nav_Menus::insert_auto_draft_post()` when inserting stubs from starter content.
 
See #38114, #38013, #34923.
Fixes #38539.


git-svn-id: https://develop.svn.wordpress.org/trunk@39038 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 20:20:54 +00:00
Drew Jaynes 32c7696700 Docs: Add a slightly less ambiguous list of return types for `rest_ensure_response()`.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39037 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 18:52:58 +00:00
Drew Jaynes deb258cd33 Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Users_Controller` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39036 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 18:51:30 +00:00
John Blackbourn 7b7164e198 Role/Capability: Introduce capability tests for promoting, removing, and deleting users, and capability tests for editing comments.
Also introduces a shared fixture for a super admin user.

See #38236


git-svn-id: https://develop.svn.wordpress.org/trunk@39035 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 18:30:03 +00:00
Drew Jaynes c8d362a3b2 Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_User_Meta_Fields` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39034 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 18:27:28 +00:00
Drew Jaynes 496d610dfc Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Terms_Controller` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39033 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 18:20:58 +00:00
Drew Jaynes 75a1951892 Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Term_Meta_Fields` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39032 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 18:08:36 +00:00
Drew Jaynes b3bb03b33a Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Taxonomies_Controller` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39031 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 18:06:23 +00:00
Drew Jaynes ed2321d7f1 Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Settings_Controller` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39030 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 18:00:24 +00:00
Drew Jaynes b58bb705ce REST: Fix some errant `else if` conditions and add a few missing periods on inline comments.
Props mrahmadawais.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39029 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 17:53:04 +00:00
Drew Jaynes 5fdf3ac313 Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Revisions_Controller` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39028 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 17:49:14 +00:00
Drew Jaynes d10a54f83c REST: Fix a yoda condition in `WP_REST_Request::get_parameter_order()` and add a missing period for an inline comment in `WP_REST_Request::from_url().
Props mrahmadawais.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39027 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 17:41:15 +00:00
Drew Jaynes ee32082734 Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Posts_Controller` class.
Props Soean, mrahmadawais, flixos90, DrewAPicture.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39026 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 17:36:15 +00:00
Drew Jaynes d3e10335d7 Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Post_Types_Controller` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39025 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 16:50:15 +00:00
Drew Jaynes 9b648569f2 Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Post_Statuses_Controller` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39024 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 16:43:12 +00:00
Drew Jaynes bc917ac0c7 Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Post_Meta_Fields` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39023 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 16:35:30 +00:00
Drew Jaynes 79ed959c30 Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Meta_Fields` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39022 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 16:32:05 +00:00
Drew Jaynes f6e25fb836 Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Controller` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39021 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 16:19:22 +00:00
John Blackbourn 765d5feb08 Customize: Avoid using `assertNotFalse()` in tests because it's not available in PHPUnit 3.6.
See #35395


git-svn-id: https://develop.svn.wordpress.org/trunk@39020 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 15:41:49 +00:00
Andrea Fercia 6f3e4849fd Accessibility: Remove target=_blank from the help tab links in network.php.
Stop taking control of users' browsers.

Props wolly.
Fixes #38572. See #23432.


git-svn-id: https://develop.svn.wordpress.org/trunk@39019 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 15:18:35 +00:00
Weston Ruter 7382bdd6b3 Customize: Prevent toggling edit shortcuts when doing shift-click or when clicking on a descendent of an interactive element.
See #38532, #27403.
Fixes #38554.


git-svn-id: https://develop.svn.wordpress.org/trunk@39018 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 14:58:47 +00:00
John Blackbourn 509df810bf Customize: Correct the CRUD tests for custom CSS on multisite.
See #35395


git-svn-id: https://develop.svn.wordpress.org/trunk@39017 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 14:03:05 +00:00
John Blackbourn 4e262ff6ee Customize: Correct the capability mapping and associated tests for the `unfiltered_css` capability.
Fixes #35395


git-svn-id: https://develop.svn.wordpress.org/trunk@39016 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 12:46:46 +00:00
Drew Jaynes db6994c8c6 Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Comments_Controller` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39015 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 06:54:49 +00:00
Drew Jaynes 6b4e878a0d Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Comment_Meta_Fields` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39014 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 06:33:34 +00:00
Drew Jaynes fff3c88cb1 Tests: Helps to also update the hour and not just the timezone to temporarily fix a test broken due to Daylight Saving Time changes in Europe.
git-svn-id: https://develop.svn.wordpress.org/trunk@39013 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 05:53:58 +00:00
Drew Jaynes 64aac0df10 Tests: Temporarily fix a test failing due to European Daylight Saving Time changes.
git-svn-id: https://develop.svn.wordpress.org/trunk@39012 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 05:43:44 +00:00
Drew Jaynes 19ef3b99e7 Docs: Add much more complete and syntactically correct documentation throughout the `WP_REST_Attachments_Controller` class.
Props Soean, mrahmadawais, flixos90.
See #38398.


git-svn-id: https://develop.svn.wordpress.org/trunk@39011 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 05:39:09 +00:00
Weston Ruter 4b478549d2 Customize: Reveal controls pane when clicking on edit shortcuts in mobile preview.
Re-use `paneVisible` state to also manage whether the mobile `preview-only` class is applied to the overlay.

Props seancjones.
See #36678, #36678, #27403.
Fixes #38080.


git-svn-id: https://develop.svn.wordpress.org/trunk@39010 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 04:22:18 +00:00
Weston Ruter a8b4e3c54b Customize: Fix message grammar for `custom_css` validity error when imbalanced characters possibly due to `content` CSS property.
Props Presskopp.
See #35395.
Fixes #38564.


git-svn-id: https://develop.svn.wordpress.org/trunk@39009 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 04:03:39 +00:00
johnbillion 5de9799317 Role/Capability: Reuse a fixture in a couple more unit tests.
See #30017


git-svn-id: https://develop.svn.wordpress.org/trunk@39008 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-30 00:32:03 +00:00
Dominik Schilling (ocean90) 249bde034d XML-RPC: Fix truncated warning message added in [38883].
See #37122.

git-svn-id: https://develop.svn.wordpress.org/trunk@39007 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-29 21:31:29 +00:00
Andrea Fercia ea885d3a26 Accessibility: Improve the form labels on the Add New User screen.
On the Multisite - single site "Add New User" screen, some form fields have more
than one label associated with them. Form controls should have at most one
associated label element. If more than one label element is associated to the
control, assistive technologies may not read the appropriate label.

Additionally, labels can be associated to their related form fields either
explicitly (using a `for` attribute referencing the field ID) or implicitly
(using the label to wrap the field). As a best practice, never do both and
prefer explicitly associated labels when possible.

Props Ankit K Gupta.
Fixes #38459.


git-svn-id: https://develop.svn.wordpress.org/trunk@39006 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-29 12:53:44 +00:00
Dominik Schilling (ocean90) 404c584956 I18N: Don't initialize `WP_Locale_Switcher` in `wp_load_translations_early()`.
`wp_load_translations_early()` is used when WordPress isn't fully initialized. Therefore using the `WP_Locale_Switcher` with `get_locale()`/`get_user_locale()` can cause PHP fatal errors.
This reverts [38976] and [38977], and instead removes `WP_Locale_Switcher` from `wp_load_translations_early()`.

See #29783.
Fixes #38535.

git-svn-id: https://develop.svn.wordpress.org/trunk@39005 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-29 11:22:50 +00:00
Tammie Lister eb68984b1b Twenty Seventeen: Fixes unexpected behaviour of scroll down arrow
This ensures the arrorw disappears once the top menu sticks.

Props LittleBigThing, davidakennedy
Fixes #38555



git-svn-id: https://develop.svn.wordpress.org/trunk@39004 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-29 09:44:10 +00:00
Weston Ruter 6e59435291 Customize: Move Additional CSS section toward end of list by assigning priority higher than default.
Props Mista-Flo.
Fixes #38524.


git-svn-id: https://develop.svn.wordpress.org/trunk@39003 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-29 05:10:36 +00:00
Weston Ruter 2982ca5872 Customize: Mark newly-added page/post stubs as added (with checkmark) when they are inserted into the list of available items.
Props ryankienstra, celloexpressions.
See #34923.
Fixes #38499.


git-svn-id: https://develop.svn.wordpress.org/trunk@39002 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-29 05:05:33 +00:00
David A. Kennedy 0599b2d13c Twenty Seventeen: Adds missing theme text domains to starter content
* Also, changes the top menu label so it has better context when read alone by assistive technology.

Props anilbasnet.

Fixes #38542.


git-svn-id: https://develop.svn.wordpress.org/trunk@39001 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-28 23:43:54 +00:00
David A. Kennedy 0890bf838e Twenty Seventeen: Don't modify excerpt link in admin
* Since this is a filter the original value is returned if `is_admin()` is true.
* Removes portion of the doc block since function is not pluggable.

Props mangeshp.

Fixes #38510.


git-svn-id: https://develop.svn.wordpress.org/trunk@39000 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-28 23:15:42 +00:00
David A. Kennedy 78a664b210 Twenty Seventeen: Remove excessive escaping in `color-patterns.php`
Uses `absint()` to escape when getting value. Removes `esc_attr` from each instance of the variable.

Props fencer04.

Fixes #38449.


git-svn-id: https://develop.svn.wordpress.org/trunk@38999 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-28 21:52:38 +00:00
Tammie Lister ae72d78fb6 Twenty Seventeen: Hidden article tags on home page fix
This prevents the issue of hidden article tags on home page.

Props ElectricFeet, iv.dimova. morettigeorgiev, davidakennedy
Fixes #38404

M    twentyseventeen/inc/template-tags.php
M    twentyseventeen/style.css


git-svn-id: https://develop.svn.wordpress.org/trunk@38998 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-28 21:00:14 +00:00
Andrew Ozz c4145b769e TinyMCE: if the current editor configuration is without toolbars, prevent errors when adding the labels for custom shortcuts.
Fixes #38063.

git-svn-id: https://develop.svn.wordpress.org/trunk@38997 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-28 20:06:02 +00:00
David A. Kennedy 3cb436603a Twenty Seventeen: Fix broken and crowded pagination navigation on small screens
* Hides page numbers visually at smaller screen sizes.
* Reduced padding around `.wrap` class on smaller screens.
* Fixed issue with the page numbers not displaying the underline on `:hover`. This has been updated in the custom colors files, too.

Props laurelfulford, caspie.

Fixes #38394.


git-svn-id: https://develop.svn.wordpress.org/trunk@38996 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-28 17:37:50 +00:00
Helen Hou-Sandi 18d1fe4c1d Post-4.7 beta 1 bump.
git-svn-id: https://develop.svn.wordpress.org/trunk@38995 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-28 04:32:19 +00:00
Weston Ruter e0817ca1f6 Customize: Remove premature (and verbose) check of `fresh_site` option due to database not being ready on multisite.
Fixes regression in [38991].
See #38114.


git-svn-id: https://develop.svn.wordpress.org/trunk@38994 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-28 03:42:08 +00:00
Weston Ruter e0bc1e0c16 Customize: Ensure that qunit test enters in expected state and tests `wp.customize.dirtyValues` in starter content context.
Fixes regression in [38991].
See #38114.


git-svn-id: https://develop.svn.wordpress.org/trunk@38993 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-28 03:28:07 +00:00
Helen Hou-Sandi db66c0d7d2 WordPress 4.7 Beta 1.
git-svn-id: https://develop.svn.wordpress.org/trunk@38992 602fd350-edb4-49c9-b593-d223f7449a82
2016-10-28 03:00:46 +00:00