<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[57602] trunk: General: Add an option to configure the site icon in general settings.</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { white-space: pre-line; overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta" style="font-size: 105%">
<dt style="float: left; width: 6em; font-weight: bold">Revision</dt> <dd><a style="font-weight: bold" href="https://core.trac.wordpress.org/changeset/57602">57602</a><script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","description":"Review this Commit","action":{"@type":"ViewAction","url":"https://core.trac.wordpress.org/changeset/57602","name":"Review Commit"}}</script></dd>
<dt style="float: left; width: 6em; font-weight: bold">Author</dt> <dd>jorbin</dd>
<dt style="float: left; width: 6em; font-weight: bold">Date</dt> <dd>2024-02-12 21:55:44 +0000 (Mon, 12 Feb 2024)</dd>
</dl>

<pre style='padding-left: 1em; margin: 2em 0; border-left: 2px solid #ccc; line-height: 1.25; font-size: 105%; font-family: sans-serif'>General: Add an option to configure the site icon in general settings.

This restores the site icon setting to its original home on the settings page where it lives with the title and tagline.

The base for this code was originally added in <a href="https://core.trac.wordpress.org/changeset/32994">[32994]</a> and then removed in <a href="https://core.trac.wordpress.org/changeset/33329">[33329]</a>. The majority of the modification to that version are to remove the no-js pieces and make the workflow completely inline rather than putting the cropping on a separate page.

Additionally, since image crops rely on the ability to upload an image, this setting is gated by the `upload_files` capability.

Follow-up to: <a href="https://core.trac.wordpress.org/changeset/32994">[32994]</a>, <a href="https://core.trac.wordpress.org/changeset/33329">[33329]</a>.

Props jorbin, audrasjb, mukesh27, joedolson, afercia, kebbet, swissspidy, obenland, jameskoster, kjellr, andraganescu, stacimc, mikeschroder, h71, krupajnanda, huzaifaalmesbah.
Fixes <a href="https://core.trac.wordpress.org/ticket/54370">#54370</a>.
See <a href="https://core.trac.wordpress.org/ticket/16434">#16434</a>.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkGruntfilejs">trunk/Gruntfile.js</a></li>
<li><a href="#trunksrcwpadmincssformscss">trunk/src/wp-admin/css/forms.css</a></li>
<li><a href="#trunksrcwpadmincsssiteiconcss">trunk/src/wp-admin/css/site-icon.css</a></li>
<li><a href="#trunksrcwpadminoptionsgeneralphp">trunk/src/wp-admin/options-general.php</a></li>
<li><a href="#trunksrcwpadminoptionsphp">trunk/src/wp-admin/options.php</a></li>
<li><a href="#trunksrcwpincludescssmediaviewscss">trunk/src/wp-includes/css/media-views.css</a></li>
<li><a href="#trunksrcwpincludesscriptloaderphp">trunk/src/wp-includes/script-loader.php</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunksrcjs_enqueuesadminsiteiconjs">trunk/src/js/_enqueues/admin/site-icon.js</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkGruntfilejs"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/Gruntfile.js</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/Gruntfile.js        2024-02-12 21:46:14 UTC (rev 57601)
+++ trunk/Gruntfile.js  2024-02-12 21:55:44 UTC (rev 57602)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -332,6 +332,7 @@
</span><span class="cx" style="display: block; padding: 0 10px">                                        [ WORKING_DIR + 'wp-admin/js/tags-suggest.js' ]: [ './src/js/_enqueues/admin/tags-suggest.js' ],
</span><span class="cx" style="display: block; padding: 0 10px">                                        [ WORKING_DIR + 'wp-admin/js/tags.js' ]: [ './src/js/_enqueues/admin/tags.js' ],
</span><span class="cx" style="display: block; padding: 0 10px">                                        [ WORKING_DIR + 'wp-admin/js/site-health.js' ]: [ './src/js/_enqueues/admin/site-health.js' ],
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                                        [ WORKING_DIR + 'wp-admin/js/site-icon.js' ]: [ './src/js/_enqueues/admin/site-icon.js' ],
</ins><span class="cx" style="display: block; padding: 0 10px">                                         [ WORKING_DIR + 'wp-admin/js/privacy-tools.js' ]: [ './src/js/_enqueues/admin/privacy-tools.js' ],
</span><span class="cx" style="display: block; padding: 0 10px">                                        [ WORKING_DIR + 'wp-admin/js/theme-plugin-editor.js' ]: [ './src/js/_enqueues/wp/theme-plugin-editor.js' ],
</span><span class="cx" style="display: block; padding: 0 10px">                                        [ WORKING_DIR + 'wp-admin/js/theme.js' ]: [ './src/js/_enqueues/wp/theme.js' ],
</span></span></pre></div>
<a id="trunksrcjs_enqueuesadminsiteiconjs"></a>
<div class="addfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Added: trunk/src/js/_enqueues/admin/site-icon.js</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/js/_enqueues/admin/site-icon.js                         (rev 0)
+++ trunk/src/js/_enqueues/admin/site-icon.js   2024-02-12 21:55:44 UTC (rev 57602)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -0,0 +1,138 @@
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+(function($) {
+       var frame;
+
+       function calculateImageSelectOptions ( attachment ) {
+               var realWidth  = attachment.get( 'width' ),
+                       realHeight = attachment.get( 'height' ),
+                       xInit = 512,
+                       yInit = 512,
+                       ratio = xInit / yInit,
+                       xImg  = xInit,
+                       yImg  = yInit,
+                       x1, y1, imgSelectOptions;
+
+               if ( realWidth / realHeight > ratio ) {
+                       yInit = realHeight;
+                       xInit = yInit * ratio;
+               } else {
+                       xInit = realWidth;
+                       yInit = xInit / ratio;
+               }
+
+               x1 = ( realWidth - xInit ) / 2;
+               y1 = ( realHeight - yInit ) / 2;
+
+               imgSelectOptions = {
+                       aspectRatio: xInit + ':' + yInit,
+                       handles: true,
+                       keys: true,
+                       instance: true,
+                       persistent: true,
+                       imageWidth: realWidth,
+                       imageHeight: realHeight,
+                       minWidth: xImg > xInit ? xInit : xImg,
+                       minHeight: yImg > yInit ? yInit : yImg,
+                       x1: x1,
+                       y1: y1,
+                       x2: xInit + x1,
+                       y2: yInit + y1
+               };
+
+               return imgSelectOptions;
+       }
+
+       $( function() {
+               // Build the choose from library frame.
+               $( '#choose-from-library-link' ).on( 'click', function() {
+                       var $el = $(this);
+
+                       // Create the media frame.
+                       frame = wp.media({
+                               button: {
+                                       // Set the text of the button.
+                                       text: $el.data('update'),
+                                       // Don't close, we might need to crop.
+                                       close: false
+                               },
+                               states: [
+                                       new wp.media.controller.Library({
+                                               title: $el.data( 'choose' ),
+                                               library: wp.media.query({ type: 'image' }),
+                                               date: false,
+                                               suggestedWidth: $el.data( 'size' ),
+                                               suggestedHeight: $el.data( 'size' )
+                                       }),
+                                       new wp.media.controller.SiteIconCropper({
+                                               control: {
+                                                       params: {
+                                                               width: $el.data( 'size' ),
+                                                               height: $el.data( 'size' )
+                                                       }
+                                               },
+                                               imgSelectOptions: calculateImageSelectOptions
+                                       })
+                               ]
+                       });
+
+                       frame.on( 'cropped', function( attachment) {
+                               $( '#site_icon_hidden_field' ).val(attachment.id);
+                               switchToUpdate(attachment.url);
+                               frame.close();
+                               // Start over with a frame that is so fresh and so clean clean.
+                               frame = null;
+                       });
+
+                       // When an image is selected, run a callback.
+                       frame.on( 'select', function() {
+                               // Grab the selected attachment.
+                               var attachment = frame.state().get('selection').first();
+
+                               if ( attachment.attributes.height === $el.data('size') && $el.data('size') === attachment.attributes.width ) {
+                                       // Set the value of the hidden input to the attachment id.
+                                       $( '#site_icon_hidden_field').val(attachment.id);
+                                       switchToUpdate(attachment.attributes.url);
+                                       frame.close();
+                               } else {
+                                       frame.setState( 'cropper' );
+                               }
+                       });
+
+                       frame.open();
+               });
+       });
+
+       function switchToUpdate( url ){
+               // Set site-icon-img src to the url and remove the hidden class.
+               $( '#site-icon-preview').find('img').not('.browser-preview').each( function(i, img ){
+                       $(img).attr('src', url );
+               });
+               $( '#site-icon-preview' ).removeClass( 'hidden' );
+               // Remove hidden class from remove.
+               $( '#js-remove-site-icon' ).removeClass( 'hidden' );
+               // If the button is not in the update state, swap the classes.
+               if( $( '#choose-from-library-link' ).attr( 'data-state' ) !== '1' ){
+                       var classes = $( '#choose-from-library-link' ).attr( 'class' );
+                       $( '#choose-from-library-link' ).attr( 'class', $( '#choose-from-library-link' ).attr('data-alt-classes') );
+                       $( '#choose-from-library-link' ).attr( 'data-alt-classes', classes );
+                       $( '#choose-from-library-link' ).attr( 'data-state', '1' );
+               }
+
+               // swap the text of the button
+               $( '#choose-from-library-link' ).text( $( '#choose-from-library-link' ).attr( 'data-update-text' ) );
+       }
+
+       $( '#js-remove-site-icon' ).on( 'click', function() {
+               $( '#site_icon_hidden_field' ).val( 'false' );
+               $( '#site-icon-preview' ).toggleClass( 'hidden' );
+               $( this ).toggleClass( 'hidden' );
+
+               var classes = $( '#choose-from-library-link' ).attr( 'class' );
+               $( '#choose-from-library-link' ).attr( 'class', $( '#choose-from-library-link' ).attr( 'data-alt-classes' ) );
+               $( '#choose-from-library-link' ).attr( 'data-alt-classes', classes );
+
+               // Swap the text of the button.
+               $( '#choose-from-library-link' ).text( $( '#choose-from-library-link' ).attr( 'data-choose-text' ) );
+               // Set the state of the button so it can be changed on new icon.
+               $( '#choose-from-library-link' ).attr( 'data-state', '');
+       });
+}(jQuery));
</ins><span class="cx" style="display: block; padding: 0 10px">Property changes on: trunk/src/js/_enqueues/admin/site-icon.js
</span><span class="cx" style="display: block; padding: 0 10px">___________________________________________________________________
</span></span></pre></div>
<a id="svneolstyle"></a>
<div class="addfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Added: svn:eol-style</h4></div>
<ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+native
</ins><span class="cx" style="display: block; padding: 0 10px">\ No newline at end of property
</span><a id="trunksrcwpadmincssformscss"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/css/forms.css</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/css/forms.css  2024-02-12 21:46:14 UTC (rev 57601)
+++ trunk/src/wp-admin/css/forms.css    2024-02-12 21:55:44 UTC (rev 57602)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -789,6 +789,42 @@
</span><span class="cx" style="display: block; padding: 0 10px">        outline: 2px solid transparent;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+.button-add-site-icon{
+       width: 100%;
+       cursor: pointer;
+       text-align: center;
+       border: 1px dashed #c3c4c7;
+       box-sizing: border-box;
+       padding: 9px 0;
+       line-height: 1.6;
+       max-width: 270px;
+}
+
+.button-add-site-icon:focus,
+.button-add-site-icon:hover{
+       background: white;
+}
+
+.site-icon-section .favicon-preview{
+       float: left;
+}
+.site-icon-section .app-icon-preview{
+       float: left;
+       margin: 0 20px;
+}
+
+.site-icon-section .site-icon-preview img{
+       max-width: 100%;
+}
+
+.button-ad-site-icon:focus{
+       background-color: #fff;
+       border-color: #3582c4;
+       border-style: solid;
+       box-shadow: 0 0 0 1px #3582c4;
+       outline: 2px solid transparent;
+}
+
</ins><span class="cx" style="display: block; padding: 0 10px"> /*------------------------------------------------------------------------------
</span><span class="cx" style="display: block; padding: 0 10px">   15.0 - Comments Screen
</span><span class="cx" style="display: block; padding: 0 10px"> ------------------------------------------------------------------------------*/
</span></span></pre></div>
<a id="trunksrcwpadmincsssiteiconcss"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/css/site-icon.css</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/css/site-icon.css      2024-02-12 21:46:14 UTC (rev 57601)
+++ trunk/src/wp-admin/css/site-icon.css        2024-02-12 21:55:44 UTC (rev 57602)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -7,6 +7,7 @@
</span><span class="cx" style="display: block; padding: 0 10px">        overflow: hidden;
</span><span class="cx" style="display: block; padding: 0 10px">        position: relative;
</span><span class="cx" style="display: block; padding: 0 10px">        max-width: 180px;
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+        float: left;
</ins><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px"> .site-icon-preview .favicon,
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -52,3 +53,20 @@
</span><span class="cx" style="display: block; padding: 0 10px"> .customize-control-site_icon .app-icon-preview {
</span><span class="cx" style="display: block; padding: 0 10px">        margin-top: 9px;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
+.site-icon-section button.reset {
+       color: #b32d2e;
+       text-decoration: none;
+       border-color: transparent;
+       box-shadow: none;
+       background: transparent;
+       margin: 0 10px;
+}
+
+.site-icon-section button.reset:focus,
+.site-icon-section button.reset:hover {
+       background: #b32d2e;
+       color: #fff;
+       border-color: #b32d2e;
+       box-shadow: 0 0 0 1px #b32d2e;
+}
</ins></span></pre></div>
<a id="trunksrcwpadminoptionsgeneralphp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/options-general.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/options-general.php    2024-02-12 21:46:14 UTC (rev 57601)
+++ trunk/src/wp-admin/options-general.php      2024-02-12 21:55:44 UTC (rev 57602)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -97,7 +97,86 @@
</span><span class="cx" style="display: block; padding: 0 10px"> <p class="description" id="tagline-description"><?php echo $tagline_description; ?></p></td>
</span><span class="cx" style="display: block; padding: 0 10px"> </tr>
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-<?php
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+<?php if ( current_user_can( 'upload_files' ) ) : ?>
+<tr class="hide-if-no-js site-icon-section">
+<th scope="row"><?php _e( 'Site Icon' ); ?></th>
+<td>
+       <?php
+       wp_enqueue_media();
+       wp_enqueue_script( 'site-icon' );
+
+       $classes_for_upload_button = 'upload-button button-add-media button-add-site-icon';
+       $classes_for_update_button = 'button';
+
+       $classes_for_avatar = 'avatar avatar-150';
+       if ( has_site_icon() ) {
+               $classes_for_avatar          .= ' has-site-icon';
+               $classes_for_button           = $classes_for_update_button;
+               $classes_for_button_on_change = $classes_for_upload_button;
+       } else {
+               $classes_for_avatar          .= ' hidden';
+               $classes_for_button           = $classes_for_upload_button;
+               $classes_for_button_on_change = $classes_for_update_button;
+       }
+
+
+       ?>
+       <div id="site-icon-preview" class="site-icon-preview wp-clearfix <?php echo esc_attr( $classes_for_avatar ); ?>">
+               <div class="favicon-preview">
+                       <img src="<?php echo esc_url( admin_url( 'images/' . ( is_rtl() ? 'browser-rtl.png' : 'browser.png' ) ) ); ?>" class="browser-preview" width="182" alt="">
+                       <div class="favicon">
+                               <img src="<?php site_icon_url(); ?>" alt="Preview as a browser icon">
+                       </div>
+                       <span class="browser-title" aria-hidden="true"><?php echo get_bloginfo( 'name' ); ?></span>
+               </div>
+               <img class="app-icon-preview" src="<?php site_icon_url(); ?>" alt="Preview as an app icon">
+       </div>
+       <input type="hidden" name="site_icon" id="site_icon_hidden_field" value="<?php form_option( 'site_icon' ); ?>" />
+       <p>
+               <button type="button"
+                       id="choose-from-library-link"
+                       type="button"
+                       class="<?php echo esc_attr( $classes_for_button ); ?>"
+                       data-alt-classes="<?php echo esc_attr( $classes_for_button_on_change ); ?>"
+                       data-size="512"
+                       data-choose-text="<?php esc_attr_e( 'Choose a Site Icon' ); ?>"
+                       data-update-text="<?php esc_attr_e( 'Change Site Icon' ); ?>"
+                       data-update="<?php esc_attr_e( 'Set as Site Icon' ); ?>"
+                       data-state="<?php echo esc_attr( has_site_icon() ); ?>"
+
+               >
+                       <?php if ( has_site_icon() ) : ?>
+                               <?php _e( 'Change Site Icon' ); ?>
+                       <?php else : ?>
+                               <?php _e( 'Choose a Site Icon' ); ?>
+                       <?php endif; ?>
+               </button>
+               <button
+                       id="js-remove-site-icon"
+                       type="button"
+                       <?php echo has_site_icon() ? 'class="button button-secondary reset"' : 'class="button button-secondary reset hidden"'; ?>
+               >
+                       <?php _e( 'Remove Site Icon' ); ?>
+               </button>
+       </p>
+
+       <p class="description" id="site-icon-description">
+               <?php _e( 'Site Icons are what you see in browser tabs, bookmark bars, and within the WordPress mobile apps. Upload one here!' ); ?>
+       </p>
+       <p class="description" id="site-icon-further-description">
+               <?php
+                       /* translators: %s: Site Icon size in pixels. */
+                       printf( __( 'Site Icons should be square and at least %s pixels.' ), '<strong>512 &times; 512</strong>' );
+               ?>
+       </p>
+
+</td>
+</tr>
+
+       <?php
+endif;
+       /* End Site Icon */
+
</ins><span class="cx" style="display: block; padding: 0 10px"> if ( ! is_multisite() ) {
</span><span class="cx" style="display: block; padding: 0 10px">        $wp_site_url_class = '';
</span><span class="cx" style="display: block; padding: 0 10px">        $wp_home_class     = '';
</span></span></pre></div>
<a id="trunksrcwpadminoptionsphp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/options.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/options.php    2024-02-12 21:46:14 UTC (rev 57601)
+++ trunk/src/wp-admin/options.php      2024-02-12 21:55:44 UTC (rev 57602)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -90,6 +90,7 @@
</span><span class="cx" style="display: block; padding: 0 10px">        'general'    => array(
</span><span class="cx" style="display: block; padding: 0 10px">                'blogname',
</span><span class="cx" style="display: block; padding: 0 10px">                'blogdescription',
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                'site_icon',
</ins><span class="cx" style="display: block; padding: 0 10px">                 'gmt_offset',
</span><span class="cx" style="display: block; padding: 0 10px">                'date_format',
</span><span class="cx" style="display: block; padding: 0 10px">                'time_format',
</span></span></pre></div>
<a id="trunksrcwpincludescssmediaviewscss"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-includes/css/media-views.css</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-includes/css/media-views.css 2024-02-12 21:46:14 UTC (rev 57601)
+++ trunk/src/wp-includes/css/media-views.css   2024-02-12 21:55:44 UTC (rev 57602)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -849,6 +849,7 @@
</span><span class="cx" style="display: block; padding: 0 10px">        height: 100%;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+.options-general-php .crop-content.site-icon,
</ins><span class="cx" style="display: block; padding: 0 10px"> .wp-customizer:not(.mobile) .media-frame-content .crop-content.site-icon {
</span><span class="cx" style="display: block; padding: 0 10px">        margin-right: 300px;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -2560,6 +2561,10 @@
</span><span class="cx" style="display: block; padding: 0 10px">                width: 230px;
</span><span class="cx" style="display: block; padding: 0 10px">        }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+        .options-general-php .crop-content.site-icon {
+               margin-right: 262px;
+       }
+
</ins><span class="cx" style="display: block; padding: 0 10px">         .attachments-browser .attachments,
</span><span class="cx" style="display: block; padding: 0 10px">        .attachments-browser .uploader-inline,
</span><span class="cx" style="display: block; padding: 0 10px">        .attachments-browser .media-toolbar,
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -2827,6 +2832,10 @@
</span><span class="cx" style="display: block; padding: 0 10px">                position: fixed;
</span><span class="cx" style="display: block; padding: 0 10px">        }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+        .options-general-php .crop-content.site-icon {
+               margin-right: 0;
+       }
+
</ins><span class="cx" style="display: block; padding: 0 10px">         .media-sidebar {
</span><span class="cx" style="display: block; padding: 0 10px">                z-index: 1900;
</span><span class="cx" style="display: block; padding: 0 10px">                max-width: 70%;
</span></span></pre></div>
<a id="trunksrcwpincludesscriptloaderphp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-includes/script-loader.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-includes/script-loader.php   2024-02-12 21:46:14 UTC (rev 57601)
+++ trunk/src/wp-includes/script-loader.php     2024-02-12 21:55:44 UTC (rev 57602)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -849,6 +849,8 @@
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px">        $scripts->add( 'wp-lists', "/wp-includes/js/wp-lists$suffix.js", array( 'wp-ajax-response', 'jquery-color' ), false, 1 );
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+        $scripts->add( 'site-icon', '/wp-admin/js/site-icon.js', array( 'jquery', 'jcrop' ), false, 1 );
+
</ins><span class="cx" style="display: block; padding: 0 10px">         // WordPress no longer uses or bundles Prototype or script.aculo.us. These are now pulled from an external source.
</span><span class="cx" style="display: block; padding: 0 10px">        $scripts->add( 'prototype', 'https://ajax.googleapis.com/ajax/libs/prototype/1.7.1.0/prototype.js', array(), '1.7.1' );
</span><span class="cx" style="display: block; padding: 0 10px">        $scripts->add( 'scriptaculous-root', 'https://ajax.googleapis.com/ajax/libs/scriptaculous/1.9.0/scriptaculous.js', array( 'prototype' ), '1.9.0' );
</span></span></pre>
</div>
</div>

</body>
</html>