Changeset 58927 for trunk/src/wp-admin/options-general.php
- Timestamp:
- 08/23/2024 10:45:54 PM (8 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/options-general.php
r57833 r58927 125 125 $browser_icon_alt_value = ''; 126 126 127 $site_icon_url = get_site_icon_url(); 128 127 129 if ( $site_icon_id ) { 128 130 $img_alt = get_post_meta( $site_icon_id, '_wp_attachment_image_alt', true ); 129 $filename = wp_basename( get_site_icon_url());131 $filename = wp_basename( $site_icon_url ); 130 132 $app_icon_alt_value = sprintf( 131 133 /* translators: %s: The selected image filename. */ … … 156 158 ?> 157 159 158 159 <div id="site-icon-preview" class="site-icon-preview wp-clearfix settings-page-preview <?php echo esc_attr( $classes_for_wrapper ); ?>"> 160 <div class="favicon-preview"> 161 <img src="<?php echo esc_url( admin_url( 'images/' . ( is_rtl() ? 'browser-rtl.png' : 'browser.png' ) ) ); ?>" class="browser-preview" width="182" alt=""> 162 <div class="favicon"> 163 <img id="browser-icon-preview" src="<?php site_icon_url(); ?>" alt="<?php echo esc_attr( $browser_icon_alt_value ); ?>"> 160 <style> 161 :root { 162 --site-icon-url: url( '<?php echo esc_url( $site_icon_url ); ?>' ); 163 } 164 </style> 165 166 <div id="site-icon-preview" class="site-icon-preview settings <?php echo esc_attr( $classes_for_wrapper ); ?>"> 167 <div class="direction-wrap"> 168 <img id="app-icon-preview" src="<?php echo esc_url( $site_icon_url ); ?>" class="app-icon-preview" alt="<?php echo esc_attr( $app_icon_alt_value ); ?>" /> 169 <div class="site-icon-preview-browser"> 170 <svg role="img" aria-hidden="true" fill="none" xmlns="http://www.w3.org/2000/svg" class="browser-buttons"><path fill-rule="evenodd" clip-rule="evenodd" d="M0 20a6 6 0 1 1 12 0 6 6 0 0 1-12 0Zm18 0a6 6 0 1 1 12 0 6 6 0 0 1-12 0Zm24-6a6 6 0 1 0 0 12 6 6 0 0 0 0-12Z" /></svg> 171 <div class="site-icon-preview-tab"> 172 <img id="browser-icon-preview" src="<?php echo esc_url( $site_icon_url ); ?>" class="browser-icon-preview" alt="<?php echo esc_attr( $browser_icon_alt_value ); ?>" /> 173 <div class="site-icon-preview-site-title" id="site-icon-preview-site-title" aria-hidden="true"><?php bloginfo( 'name' ); ?></div> 174 <svg role="img" aria-hidden="true" fill="none" xmlns="http://www.w3.org/2000/svg" class="close-button"> 175 <path d="M12 13.0607L15.7123 16.773L16.773 15.7123L13.0607 12L16.773 8.28772L15.7123 7.22706L12 10.9394L8.28771 7.22705L7.22705 8.28771L10.9394 12L7.22706 15.7123L8.28772 16.773L12 13.0607Z" /> 176 </svg> 177 </div> 178 </div> 164 179 </div> 165 <span id="site-icon-preview-site-title" class="browser-title" aria-hidden="true"><?php bloginfo( 'name' ); ?></span>166 180 </div> 167 <img id="app-icon-preview" class="app-icon-preview" src="<?php site_icon_url(); ?>" alt="<?php echo esc_attr( $app_icon_alt_value ); ?>">168 181 </div> 169 182 170 183 <input type="hidden" name="site_icon" id="site_icon_hidden_field" value="<?php form_option( 'site_icon' ); ?>" /> 171 <div class=" action-buttons">184 <div class="site-icon-action-buttons"> 172 185 <button type="button" 173 186 id="choose-from-library-button" … … 191 204 id="js-remove-site-icon" 192 205 type="button" 193 <?php echo has_site_icon() ? 'class="button button-secondary reset "' : 'class="button button-secondary reset hidden"'; ?>206 <?php echo has_site_icon() ? 'class="button button-secondary reset remove-site-icon"' : 'class="button button-secondary reset hidden"'; ?> 194 207 > 195 208 <?php _e( 'Remove Site Icon' ); ?> … … 199 212 <p class="description"> 200 213 <?php 201 /* translators: %s: Site Icon size in pixels. */ 202 printf( __( 'The Site Icon is what you see in browser tabs, bookmark bars, and within the WordPress mobile apps. It should be square and at least %s pixels.' ), '<code>512 × 512</code>' ); 214 printf( 215 /* translators: 1: pixel value for icon size. 2: pixel value for icon size. */ 216 __( 'The Site Icon is what you see in browser tabs, bookmark bars, and within the WordPress mobile apps. It should be square and at least <code>%1$s by %2$s</code> pixels.' ), 217 512, 218 512 219 ); 203 220 ?> 204 221 </p>
Note: See TracChangeset
for help on using the changeset viewer.