From 8f4774104bdb32334c33e2258169f5221a2b042f Mon Sep 17 00:00:00 2001 From: Konstantin Obenland Date: Thu, 2 Jul 2015 17:15:47 +0000 Subject: [PATCH] Site Icon: Show correct background preview for transparent images. iOS will show transparent parts as black, where as the icon itself stays transparent when used as a favicon. See #16434. git-svn-id: https://develop.svn.wordpress.org/trunk@33049 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/css/site-icon.css | 1 + src/wp-admin/js/site-icon-crop.js | 1 + 2 files changed, 2 insertions(+) diff --git a/src/wp-admin/css/site-icon.css b/src/wp-admin/css/site-icon.css index 8a4d428d8a..5d8a1b3d96 100644 --- a/src/wp-admin/css/site-icon.css +++ b/src/wp-admin/css/site-icon.css @@ -49,6 +49,7 @@ } .site-icon-crop-preview-homeicon { + background-color: #000; -webkit-border-radius: 16px; border-radius: 16px; height: 64px; diff --git a/src/wp-admin/js/site-icon-crop.js b/src/wp-admin/js/site-icon-crop.js index ebe727454e..c2b434eb6f 100644 --- a/src/wp-admin/js/site-icon-crop.js +++ b/src/wp-admin/js/site-icon-crop.js @@ -39,6 +39,7 @@ ready: function() { jcrop_api = $.Jcrop( '#crop-image' ); jcrop_api.setOptions({ + bgColor: 'transparent', aspectRatio: 1, onSelect: siteIconCrop.updateCoords, onChange: siteIconCrop.updateCoords,