mirror of
https://github.com/WordPress/five-for-the-future.git
synced 2025-04-12 06:53:44 +03:00
parent
26e6def921
commit
71fa5ab5d3
|
@ -92,6 +92,10 @@
|
||||||
|
|
||||||
<!-- print_r() is perfectly accepted in some circumstances, like WP_CLI commands. -->
|
<!-- print_r() is perfectly accepted in some circumstances, like WP_CLI commands. -->
|
||||||
<exclude name="WordPress.PHP.DevelopmentFunctions.error_log_print_r" />
|
<exclude name="WordPress.PHP.DevelopmentFunctions.error_log_print_r" />
|
||||||
|
|
||||||
|
<!-- Exclude short array syntax as it is consistently already in the codebase :) -->
|
||||||
|
<exclude name="Generic.Arrays.DisallowShortArraySyntax"/>
|
||||||
|
<exclude name="Universal.Arrays.DisallowShortArraySyntax"/>
|
||||||
</rule>
|
</rule>
|
||||||
|
|
||||||
<!-- Ignore the CPT template filename, since it is based on the CPT name, and can't change. -->
|
<!-- Ignore the CPT template filename, since it is based on the CPT name, and can't change. -->
|
||||||
|
|
|
@ -125,7 +125,7 @@ function scripts() {
|
||||||
wp_enqueue_style(
|
wp_enqueue_style(
|
||||||
'wporg-style',
|
'wporg-style',
|
||||||
get_theme_file_uri( '/css/style.css' ),
|
get_theme_file_uri( '/css/style.css' ),
|
||||||
array( 'dashicons', 'open-sans' ),
|
[ 'dashicons', 'open-sans' ],
|
||||||
filemtime( __DIR__ . '/css/style.css' )
|
filemtime( __DIR__ . '/css/style.css' )
|
||||||
);
|
);
|
||||||
|
|
||||||
|
@ -192,7 +192,7 @@ add_action( 'wp_body_open', __NAMESPACE__ . '\nojs_body_tag' );
|
||||||
* @return string
|
* @return string
|
||||||
*/
|
*/
|
||||||
function loader_src( $src, $handle ) {
|
function loader_src( $src, $handle ) {
|
||||||
$cdn_urls = array(
|
$cdn_urls = [
|
||||||
'dashicons',
|
'dashicons',
|
||||||
'wp-embed',
|
'wp-embed',
|
||||||
'jquery-core',
|
'jquery-core',
|
||||||
|
@ -205,7 +205,7 @@ function loader_src( $src, $handle ) {
|
||||||
'wporg-plugins-stats',
|
'wporg-plugins-stats',
|
||||||
'wporg-plugins-client',
|
'wporg-plugins-client',
|
||||||
'wporg-plugins-faq',
|
'wporg-plugins-faq',
|
||||||
);
|
];
|
||||||
|
|
||||||
if ( defined( 'WPORG_SANDBOXED' ) && WPORG_SANDBOXED ) {
|
if ( defined( 'WPORG_SANDBOXED' ) && WPORG_SANDBOXED ) {
|
||||||
return $src;
|
return $src;
|
||||||
|
@ -217,7 +217,7 @@ function loader_src( $src, $handle ) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Remove version argument.
|
// Remove version argument.
|
||||||
if ( in_array( $handle, array( 'open-sans' ), true ) ) {
|
if ( in_array( $handle, [ 'open-sans' ], true ) ) {
|
||||||
$src = remove_query_arg( 'ver', $src );
|
$src = remove_query_arg( 'ver', $src );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -281,14 +281,14 @@ function get_badge_classes( $team ) {
|
||||||
$classes = array( 'badge-openverse', 'dashicons-search' );
|
$classes = array( 'badge-openverse', 'dashicons-search' );
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'plugin review team':
|
|
||||||
$classes = array( 'badge-plugins-reviewer', 'dashicons-admin-plugins' );
|
|
||||||
break;
|
|
||||||
|
|
||||||
case 'photos team':
|
case 'photos team':
|
||||||
$classes = array( 'badge-photos', 'dashicons-camera' );
|
$classes = array( 'badge-photos', 'dashicons-camera' );
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case 'plugin review team':
|
||||||
|
$classes = array( 'badge-plugins-reviewer', 'dashicons-admin-plugins' );
|
||||||
|
break;
|
||||||
|
|
||||||
case 'polyglots team':
|
case 'polyglots team':
|
||||||
$classes = array( 'badge-translation-editor', 'dashicons-translation' );
|
$classes = array( 'badge-translation-editor', 'dashicons-translation' );
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue