Commit Graph

63 Commits

Author SHA1 Message Date
Sergey Biryukov
054610e276 Text Changes: Remove use of "normal" in user-facing output.
This clarifies some messages referring to Site Health checks and maintenance mode, and makes them more accurate.

Props dartiss.
Fixes #50549.
Built from https://develop.svn.wordpress.org/trunk@48287


git-svn-id: http://core.svn.wordpress.org/trunk@48056 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-07-03 21:59:03 +00:00
Sergey Biryukov
c892c420b7 Docs: Miscellaneous DocBlock corrections.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48198


git-svn-id: http://core.svn.wordpress.org/trunk@47967 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-28 11:53:04 +00:00
Sergey Biryukov
56342b8e8f Docs: Replace "AJAX" with "Ajax" in DocBlocks and comments, per the spelling glossary.
Props mukesh27, sabernhardt, SergeyBiryukov.
Fixes #50064.
Built from https://develop.svn.wordpress.org/trunk@48168


git-svn-id: http://core.svn.wordpress.org/trunk@47937 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-25 12:43:07 +00:00
desrosj
4b60af1a6a General: Remove “whitelist” and “blacklist” in favor of more clear and inclusive language.
“The WordPress open source community cares about diversity. We strive to maintain a welcoming environment where everyone can feel included.”

With this commit, all occurrences of “whitelist” and “blacklist” (with the single exception of the `$new_whitelist_options` global variable) are removed. A new ticket has been opened to explore renaming the `$new_whitelist_options` variable (#50434).

Changing to more specific names or rewording sentences containing these terms not only makes the code more inclusive, but also helps provide clarity. These terms are often ambiguous. What is being blocked or allowed is not always immediately clear. This can make it more difficult for non-native English speakers to read through the codebase.

Words matter. If one contributor feels more welcome because these terms are removed, this was worth the effort.

Props strangerstudios, jorbin, desrosj, joemcgill, timothyblynjacobs, ocean90, ayeshrajans, davidbaumwald, earnjam.
See #48900, #50434.
Fixes #50413.
Built from https://develop.svn.wordpress.org/trunk@48121


git-svn-id: http://core.svn.wordpress.org/trunk@47890 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-22 17:26:13 +00:00
Sergey Biryukov
a576a13246 Docs: Remove an empty line between @param and @return tags, per the documentation standards.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48102


git-svn-id: http://core.svn.wordpress.org/trunk@47871 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-20 11:18:09 +00:00
Sergey Biryukov
d528d7a044 Site Health: Use WP_Theme::parent() in the inactive themes test as a more reliable check that the parent theme exists.
This is also more consistent with the other instances of directly referencing `WP_Theme::parent()` properties or methods in core.

Props mukesh27, juanlopez4691, davidbaumwald, afragen, SergeyBiryukov.
Fixes #49934.
Built from https://develop.svn.wordpress.org/trunk@47815


git-svn-id: http://core.svn.wordpress.org/trunk@47591 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-05-18 04:38:10 +00:00
Sergey Biryukov
9782eb82ad Site Health: Display the original PHP memory limit on Site Health Info screen.
This ensures that if the limit has been modified for admin screens by `wp_raise_memory_limit()`, the original value is displayed along with the current value.

Props Clorith, espiat, zodiac1978, SergeyBiryukov.
Fixes #49329.
Built from https://develop.svn.wordpress.org/trunk@47762


git-svn-id: http://core.svn.wordpress.org/trunk@47538 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-05-05 18:58:09 +00:00
Sergey Biryukov
5371e3fd62 Site Health: Avoid a PHP notice in WP_Site_Health::wp_cron_scheduled_check() if async test response does not contain the expected result.
Additionally, avoid a PHP notice in `::get_test_php_version()` if the minimum recommended version of PHP could not be determined.

Props schlessera, oakesjosh.
Fixes #49943.
Built from https://develop.svn.wordpress.org/trunk@47628


git-svn-id: http://core.svn.wordpress.org/trunk@47403 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-04-27 22:01:08 +00:00
Sergey Biryukov
92538d89ee Site Health: Detect an active PHP session as a possible reason for HTTP requests timing out.
PHP sessions created by a `session_start()` function call may interfere with REST API and loopback requests.

An active session should be closed by `session_write_close()` before making any HTTP requests.

Props matthieumota, netweblogic, Clorith, afragen, vjik, SergeyBiryukov.
Fixes #47320.
Built from https://develop.svn.wordpress.org/trunk@47585


git-svn-id: http://core.svn.wordpress.org/trunk@47360 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-04-16 08:20:09 +00:00
Sergey Biryukov
764a1761aa Site Health: Correct markup in ::get_test_php_extensions() and ::get_test_background_updates() description.
These tests output an unordered list, which doesn't need to be wrapped in a paragraph tag.

Additionally, pass an empty string as an `actions` parameter in `::get_test_php_default_timezone()`, for consistency with other tests.

Props afercia.
See #48948.
Built from https://develop.svn.wordpress.org/trunk@47528


git-svn-id: http://core.svn.wordpress.org/trunk@47303 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-03-29 03:46:06 +00:00
Sergey Biryukov
cf75b95197 Site Health: Run the first scheduled site health check a day after the initial site setup.
This reduces the chance of displaying incorrect results due to running the check too early in first time setup scenarios.

Props Clorith, garrett-eclipse, roytanck, joostdevalk.
Fixes #49577.
Built from https://develop.svn.wordpress.org/trunk@47456


git-svn-id: http://core.svn.wordpress.org/trunk@47243 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-03-14 16:36:07 +00:00
desrosj
447536a0e6 Site Health: Display the REST API test error codes correctly.
This change fixes an issue where the error codes associated with failed REST API tests are not being printed to the screen. In addition, the square brackets have been replaced with parentheses for consistency, and the error code (which is much less useful to end-users than the error message itself) has been moved to the end of the line.

This also clarifies the associated translator comments.

Props afercia, desrosj.
Fixes #49426.
Built from https://develop.svn.wordpress.org/trunk@47306


git-svn-id: http://core.svn.wordpress.org/trunk@47106 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-18 16:48:06 +00:00
Sergey Biryukov
055af2b506 Site Health: Improve the wording for PHP update recommendations.
Props Clorith, grafruessel, sathyapulse, wpgurudev, garrett-eclipse, marybaum, xkon, SergeyBiryukov.
Fixes #48716.
Built from https://develop.svn.wordpress.org/trunk@47254


git-svn-id: http://core.svn.wordpress.org/trunk@47054 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-11 00:41:05 +00:00
Sergey Biryukov
d98fe66044 Site Health: Move the warning about WP_DEBUG_LOG being publicly accessible from "critical issues" to "recommended improvements" if the error log is outside of the WordPress directory.
Props afragen, Clorith, miss_jwo, mikeschroder, kubiq, xkon.
Fixes #47985.
Built from https://develop.svn.wordpress.org/trunk@47235


git-svn-id: http://core.svn.wordpress.org/trunk@47035 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-10 05:16:07 +00:00
Sergey Biryukov
e713bf9a88 Site Health: Only get MySQL server information in tests where it's actually needed.
This resolves an issue with plugins like HyperDB, which doesn't have a database connection until a query is made.

Props xkon, Otto42, Clorith.
See #47606.
Built from https://develop.svn.wordpress.org/trunk@47215


git-svn-id: http://core.svn.wordpress.org/trunk@47015 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-08 20:10:05 +00:00
Sergey Biryukov
47ed56f38f Code Modernization: Replace dirname( __FILE__ ) calls with __DIR__ magic constant.
This avoids the performance overhead of the function call every time `dirname( __FILE__ )` was used instead of `__DIR__`.

This commit also includes:

* Removing unnecessary parentheses from `include`/`require` statements. These are language constructs, not function calls.
* Replacing `include` statements for several files with `require_once`, for consistency:
 * `wp-admin/admin-header.php`
 * `wp-admin/admin-footer.php`
 * `wp-includes/version.php`

Props ayeshrajans, desrosj, valentinbora, jrf, joostdevalk, netweb.
Fixes #48082.
Built from https://develop.svn.wordpress.org/trunk@47198


git-svn-id: http://core.svn.wordpress.org/trunk@46998 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-06 06:33:11 +00:00
Sergey Biryukov
0aff1cf6bd Site Health: Rename WP_Site_Health::initialize() introduced in [47063] to ::get_instance(), for clarity and consistency with other core classes.
Use `WP_Site_Health::get_instance()` where it's needed, instead of creating multiple instances of the class.

Props afercia, xkon, Clorith, SergeyBiryukov.
See #47606.
Built from https://develop.svn.wordpress.org/trunk@47149


git-svn-id: http://core.svn.wordpress.org/trunk@46949 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-01 00:39:09 +00:00
Sergey Biryukov
001ffe81fb Docs: Improve inline comments per the documentation standards.
Includes minor code layout fixes for better readability.

See #48303.
Built from https://develop.svn.wordpress.org/trunk@47122


git-svn-id: http://core.svn.wordpress.org/trunk@46922 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-29 00:45:18 +00:00
Sergey Biryukov
2c4480958b Site Health: Introduce Site Health Status dashboard widget.
The widget informs administrators of any potential issues that should be addressed to improve the performance or security of their website, and directs them to the Site Health screen for more details.

Props Clorith, hedgefield, guddu1315.
See #47606.
Built from https://develop.svn.wordpress.org/trunk@47063


git-svn-id: http://core.svn.wordpress.org/trunk@46863 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-12 13:33:05 +00:00
Sergey Biryukov
acd0a3ca99 Site Health: Add a test for PHP default timezone.
The test reports a failure if the default timezone was changed with `date_default_timezone_set()` to anything other than `UTC`.

WordPress historically uses `UTC` as the default timezone for calculating date and time offsets, overriding it is not recommended and can cause widespread and obscure issues.

Props Rarst, Clorith, TimothyBlynJacobs.
Fixes #48692.
Built from https://develop.svn.wordpress.org/trunk@46797


git-svn-id: http://core.svn.wordpress.org/trunk@46597 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-11-28 15:48:03 +00:00
Sergey Biryukov
f1b5f2aa94 Site Health: Improve the wording for UTF8MB4 test description.
Props garrett-eclipse, chetan200891, johnjamesjacoby, ayeshrajans.
Fixes #48044.
Built from https://develop.svn.wordpress.org/trunk@46402


git-svn-id: http://core.svn.wordpress.org/trunk@46201 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-10-05 02:39:58 +00:00
desrosj
ae29987a17 Site Health: Improve the message displayed to sites not utilizing HTTPS.
The new message better illustrates that there are many potential benefits of using HTTPS, not just a few.

Props garrett-eclipse, dkarfa, ocean90, afragen, desrosj.
Fixes #48118.
Built from https://develop.svn.wordpress.org/trunk@46358


git-svn-id: http://core.svn.wordpress.org/trunk@46157 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-30 17:54:58 +00:00
desrosj
894e133d0c Build/Test Tools: Introduce automated PHP compatibility checking.
This change introduces a new Composer script, `compat` that will scan the codebase for (detectable) potential PHP compatibility issues using the `PHP_CodeSniffer` and a custom ruleset based off of the `PHPCompayibilityWP` ruleset (`phpcompat.xml.dist`).

The command will be run as a separate job within each Travis build. While many compatibility issues and false positives have already been corrected in this commit and other Trac tickets, there are still some remaining. For that reason, the job is allowed to fail while the remainder of the potential compatibility issues are investigated and addressed. After those are resolved, the job should be set as required to pass to help prevent new compatibility issues from being introduced.

Props desrosj, jrf, all PHPCompatibilityWP and PHPCompatibility contributors.
Fixes #46152.
Built from https://develop.svn.wordpress.org/trunk@46290


git-svn-id: http://core.svn.wordpress.org/trunk@46102 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-25 13:47:58 +00:00
Sergey Biryukov
371f83cfd1 Site Health: Introduce site_status_test_result filter for the output of a finished Site Health test.
Props Clorith.
Fixes #47864.
Built from https://develop.svn.wordpress.org/trunk@46269


git-svn-id: http://core.svn.wordpress.org/trunk@46081 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-23 20:04:58 +00:00
Sergey Biryukov
db5f9f7a3a Site Health: Update PHP extension tests to reflect the current state of the Hosting Teams handbook recommendations.
Props Clorith, bronsonquick, jrf, johnbillion, galbaras, mikeschroder, jorbin.
Fixes #47454.
Built from https://develop.svn.wordpress.org/trunk@46268


git-svn-id: http://core.svn.wordpress.org/trunk@46080 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-23 19:50:56 +00:00
Sergey Biryukov
9510aaecde Site Health: Improve wording for PHP update warning.
Props danieltj, garrett-eclipse, marybaum, afragen, chetan200891.
Fixes #47644.
Built from https://develop.svn.wordpress.org/trunk@46267


git-svn-id: http://core.svn.wordpress.org/trunk@46079 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-23 19:39:58 +00:00
Dominik Schilling
123b4475b0 Site Health: Don't verify SSL certificate when testing the local site.
The SSL certificate may be self-signed which prevents various tests from returning proper results. Since the Cron API and file editors don't verify the certificate the tests shouldn't either.

Props Clorith, ocean90.
Fixes #47957.
Built from https://develop.svn.wordpress.org/trunk@46231


git-svn-id: http://core.svn.wordpress.org/trunk@46043 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-21 16:06:57 +00:00
Sergey Biryukov
e199663322 I18N: Capitalize translator comments consistently, add trailing punctuation.
Includes minor code layout fixes.

See #44360.
Built from https://develop.svn.wordpress.org/trunk@45932


git-svn-id: http://core.svn.wordpress.org/trunk@45743 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-03 00:41:05 +00:00
Sergey Biryukov
6cad27efcd Site Health: Standardize on SELECT VERSION() query for checking the database server version, due to the MariaDB version declaration potentially causing issues in production environments.
Partially reverts [45691].

Props Clorith.
Fixes #47738.
Built from https://develop.svn.wordpress.org/trunk@45904


git-svn-id: http://core.svn.wordpress.org/trunk@45715 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-08-28 03:09:52 +00:00
Sergey Biryukov
d85ba82d8e Docs: Add missing @since tag for WP_Site_Health::has_late_cron().
See #47223.
Built from https://develop.svn.wordpress.org/trunk@45803


git-svn-id: http://core.svn.wordpress.org/trunk@45614 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-08-15 00:42:55 +00:00
Peter Wilson
a56256d158 Site Health Check: Increase time allowance for cron checks.
Introduces `WP_Site_Health::has_late_cron()` for late wp-cron jobs and extends the time allowance before a job is considered missed.

In a standard configuration using loopback requests, a job is considered late once past due and missed over five minutes past due.

Late and missed time frames are extended if `DISABLE_WP_CRON` is defined as `true` to allow for crontab tasks running less frequently. A job is considered late once it's 15 minutes past due and missed over one hour past due.

A file for site health unit tests has been introduced with tests for cron in critical, late and missed states.

Props rockfire, afragen, peterwilsoncc.
Fixes #47223.

Built from https://develop.svn.wordpress.org/trunk@45801


git-svn-id: http://core.svn.wordpress.org/trunk@45612 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-08-15 00:35:55 +00:00
Sergey Biryukov
702ee129ad Docs: Fix typo in a comment in WP_Site_Health::get_test_theme_version().
See #47110.
Built from https://develop.svn.wordpress.org/trunk@45733


git-svn-id: http://core.svn.wordpress.org/trunk@45544 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-08-04 00:48:56 +00:00
Sergey Biryukov
fd83290995 Site Health: If WP_DEFAULT_THEME doesn't exist, use WP_Theme::get_core_default_theme() as a fallback.
Props ajayghaghretiya1, juliobox, SergeyBiryukov.
Fixes #47299.
Built from https://develop.svn.wordpress.org/trunk@45732


git-svn-id: http://core.svn.wordpress.org/trunk@45543 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-08-04 00:02:55 +00:00
Sergey Biryukov
a59301c2ba Site Health: Consistently use wpdb::db_version() for checking the database server version, instead of partically replicating its functionality.
Props Clorith, wpfed.
Fixes #47738.
Built from https://develop.svn.wordpress.org/trunk@45691


git-svn-id: http://core.svn.wordpress.org/trunk@45502 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-07-28 14:55:57 +00:00
Sergey Biryukov
66afb60397 Site Health: Use consistent verbiage for "Learn more" links.
Props ronakganatra, garrett-eclipse.
Fixes #47302.
Built from https://develop.svn.wordpress.org/trunk@45649


git-svn-id: http://core.svn.wordpress.org/trunk@45460 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-07-16 22:28:57 +00:00
Sergey Biryukov
e5ad773194 I18N: Merge duplicate "Your plugins/themes/translations are all up to date" strings.
Props ramiy.
Fixes #47252.
Built from https://develop.svn.wordpress.org/trunk@45647


git-svn-id: http://core.svn.wordpress.org/trunk@45458 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-07-16 22:13:58 +00:00
Sergey Biryukov
e68fe165ae Site Health: In PHP modules test description, move the space before the screen reader text out from the translatable string.
Props ocean90, tobifjellner.
Fixes #47161.
Built from https://develop.svn.wordpress.org/trunk@45346


git-svn-id: http://core.svn.wordpress.org/trunk@45157 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-17 11:50:58 +00:00
Sergey Biryukov
cbad1109f4 Site Health: Use correct singular string for plugin and theme version tests.
Props edocev, Presskopp.
Fixes #47264.
Built from https://develop.svn.wordpress.org/trunk@45336


git-svn-id: http://core.svn.wordpress.org/trunk@45147 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-17 01:00:54 +00:00
Sergey Biryukov
a9fc042377 Site Health: In PHP modules test, ensure the description is translated as a whole sentence, not as separate string parts.
Props dimadin, SergeyBiryukov.
Fixes #47161.
Built from https://develop.svn.wordpress.org/trunk@45331


git-svn-id: http://core.svn.wordpress.org/trunk@45142 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-17 00:07:54 +00:00
Sergey Biryukov
9c1a666249 Site Health: In HTTP requests test, when checking whether the WP_HTTP_BLOCK_EXTERNAL constant is defined, check its value as well.
Props chesio.
Fixes #47297.
Built from https://develop.svn.wordpress.org/trunk@45328


git-svn-id: http://core.svn.wordpress.org/trunk@45139 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-16 22:08:54 +00:00
desrosj
f48f926077 Site Health: Improve vertical alignment of icons in test result descriptions.
This change removes redundant CSS properties for different health check statuses in favor of utilizing the `.dashicons` class already in Core to define them more consistently. This also fixes the vertical alignment issues.

Props chetan200891, Clorith, desrosj.
Fixes #46940.
Built from https://develop.svn.wordpress.org/trunk@45309


git-svn-id: http://core.svn.wordpress.org/trunk@45120 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-15 14:26:07 +00:00
desrosj
7d04482650 Site Health: Link to the correct plugin update screen in multisite installs.
Props Clorith, sebastienserre, jeremyfelt, desrosj.
Fixes #47189.
Built from https://develop.svn.wordpress.org/trunk@45308


git-svn-id: http://core.svn.wordpress.org/trunk@45119 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-15 14:13:05 +00:00
desrosj
6ac1d4ec1a Site Health: Disable recommendations that could be problematic on multisite installs.
When viewing Site Health for a multisite install, there are a few recommendations that are not appropriate and could have negative implications for other sites on the install if the administrator follows the advice provided.

For example, Site Health recommends that inactive plugins and themes for a site should be removed. On a single site install, this is a great recommendation. However, on a multisite install, inactive plugins and themes for one site should not be removed because they could be active for other sites on the network.

This change also disables the `test_wp_version_check_attached()` test for multisite. This test checks for the presence of the `wp_version_check()` function on the `wp_version_check` hook, which is not present for every site on multisite.

Reviewed by jeremyfelt and desrosj.

Props iandunn, Clorith, azaozz, jeremyfelt.
Fixes #47084.
Built from https://develop.svn.wordpress.org/trunk@45275


git-svn-id: http://core.svn.wordpress.org/trunk@45084 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-01 18:08:53 +00:00
Andrew Ozz
0da8c2265f Site Health: Fix count of inactive themes and the recommendation to remove them when the default theme is active or is a parent of the active child theme.
Props sudhiryadav, ianbelanger, mukesh27, azaozz.
Fixes #46900.
Built from https://develop.svn.wordpress.org/trunk@45260


git-svn-id: http://core.svn.wordpress.org/trunk@45069 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-23 21:37:53 +00:00
Sergey Biryukov
23de32062e Site Health: Allow any callable added via site_status_tests filter to return test results for direct tests.
Async tests still need to be a string for the AJAX action.

Props kraftbj.
Fixes #46836.
Built from https://develop.svn.wordpress.org/trunk@45234


git-svn-id: http://core.svn.wordpress.org/trunk@45043 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-17 14:35:50 +00:00
Sergey Biryukov
394d3b2f9b Site Health: Merge duplicate "utf8mb4 requires a newer client library" strings.
Props ramiy.
Fixes #46917.
Built from https://develop.svn.wordpress.org/trunk@45196


git-svn-id: http://core.svn.wordpress.org/trunk@45005 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-13 18:18:52 +00:00
Sergey Biryukov
f94f0684b1 Site Health: Merge duplicate "Error" strings.
Props ramiy.
Fixes #46915.
Built from https://develop.svn.wordpress.org/trunk@45195


git-svn-id: http://core.svn.wordpress.org/trunk@45004 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-13 18:12:52 +00:00
Sergey Biryukov
1ae11820fc Site Health: i18n audit, take 2.
* Use `wp.i18n` to translate JavaScript strings.
* Use `_n()` for proper plural forms support.

Props TimothyBlynJacobs, ocean90, afercia.
Fixes #46683.
Built from https://develop.svn.wordpress.org/trunk@45178


git-svn-id: http://core.svn.wordpress.org/trunk@44987 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-12 20:34:51 +00:00
desrosj
6afe73667c Site Health: Add missing actions to tests.
This change adds missing actions for several tests. This ensures that the user is provided with a next step, whenever possible.

Also, change the URL displayed in the WordPress.org communication test description to `api.wordpress.org` for accuracy.

Props: garrett-eclipse, Clorith, vaishalipanchal.
Fixes #46734.
Built from https://develop.svn.wordpress.org/trunk@45170


git-svn-id: http://core.svn.wordpress.org/trunk@44979 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-12 17:40:53 +00:00
desrosj
5bafb4ea2d Site Health: Improve the test badge implementation.
Label badges for each Site Health test currently display in either red, orange, or green, regardless of if the test passed or failed. This is confusing, as seeing red labels in the “Passed Test” section could alarm users (when really everything is OK and no action is required), and seeing green labels in the “Failed Tests” section would not appropriately encourage the user to take appropriate action.

This change makes several improvements to the label badges:

- Always right align the badges for consistent display.
- Remove background fill for badges. Instead, use a border.
- Use a consistent styling for all tests (passed and failed).
- The text color no longer uses true black (#000000).
- The `.badge.pink` CSS definition has been switched to `.badge.purple`, and the definitions for blue, gray, and green have also been updated to more closely follow the official WordPress color palette.

Props: pbiron, garrett-eclipse, hedgefield, Clorith, xkon, melchoyce, mdwolinski, alexdenning.
Fixes #46623.
Built from https://develop.svn.wordpress.org/trunk@45169


git-svn-id: http://core.svn.wordpress.org/trunk@44978 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-04-12 17:04:52 +00:00