Ticket #47369: 47369.diff
File 47369.diff, 2.7 KB (added by , 5 years ago) |
---|
-
src/wp-admin/admin-header.php
91 91 decimalPoint = '<?php echo addslashes( $wp_locale->number_format['decimal_point'] ); ?>', 92 92 isRtl = <?php echo (int) is_rtl(); ?>; 93 93 </script> 94 <meta name="viewport" content="width=device-width,initial-scale=1.0">95 94 <?php 96 95 97 96 /** -
src/wp-admin/customize.php
132 132 133 133 if ( wp_is_mobile() ) : 134 134 $body_class .= ' mobile'; 135 136 ?> 137 <meta name="viewport" id="viewport-meta" content="width=device-width, initial-scale=1.0, minimum-scale=0.5, maximum-scale=1.2" /> 138 <?php 135 add_filter( 'admin_viewport_meta', '_customizer_mobile_viewport_meta' ); 139 136 endif; 140 137 141 138 if ( $wp_customize->is_ios() ) { … … 171 168 * @since 3.4.0 172 169 */ 173 170 do_action( 'customize_controls_print_scripts' ); 171 172 /** 173 * Fires when Customizer control scripts are printed. 174 * 175 * @since 5.3.0 176 */ 177 do_action( 'customize_controls_head' ); 174 178 ?> 175 179 </head> 176 180 <body class="<?php echo esc_attr( $body_class ); ?>"> -
src/wp-admin/includes/admin-filters.php
43 43 add_action( 'admin_head', 'wp_admin_canonical_url' ); 44 44 add_action( 'admin_head', 'wp_color_scheme_settings' ); 45 45 add_action( 'admin_head', 'wp_site_icon' ); 46 add_action( 'admin_head', '_ipad_meta' ); 46 add_action( 'admin_head', 'wp_admin_viewport_meta' ); 47 add_action( 'customize_controls_head', 'wp_admin_viewport_meta' ); 47 48 48 49 // Prerendering. 49 50 if ( ! is_customize_preview() ) { -
src/wp-admin/includes/misc.php
939 939 } 940 940 941 941 /** 942 * @since 3.3.0942 * @since 5.3.0 943 943 */ 944 function _ipad_meta() { 945 if ( wp_is_mobile() ) { 944 function wp_admin_viewport_meta() { 945 $viewport_meta = apply_filters( 'admin_viewport_meta', 'width=device-width,initial-scale=1.0' ); 946 if ( ! empty( $viewport_meta ) ) : 946 947 ?> 947 <meta name="viewport" id="viewport-meta" content=" width=device-width, initial-scale=1">948 <meta name="viewport" id="viewport-meta" content="<?php echo esc_attr( $viewport_meta ); ?>"> 948 949 <?php 949 } 950 endif; 951 } 952 953 /** 954 * @since 5.3.0 955 */ 956 function _customizer_mobile_viewport_meta( $content ) { 957 return trim( $content, ',' ) . ',minimum-scale=0.5,maximum-scale=1.2'; 950 958 } 951 959 952 960 /**