Adds WP_Customize_Setting->sanitize_js_callback and 'customize_sanitize_js_$settingID' filter, to filter values before they're passed to JS using WP_Customize_Setting->js_value().
Adds support for regular hex colors to the color picker.
Changes color methods:
* sanitize_hex_color() accepts 3 and 6 digit hex colors (with hashes) and the empty string.
* sanitize_hex_color_no_hash() accepts 3 and 6 digit hex colors (without hashes) and the empty string.
* maybe_hash_hex_color() ensures that a hex color has a hash, and otherwise leaves the value untouched.
git-svn-id: https://develop.svn.wordpress.org/trunk@20936 602fd350-edb4-49c9-b593-d223f7449a82
Bind drag/drop support checks to individual plupload instances.
Add drag-over classes to wp.Uploader and corresponding styles to customize image controls.
git-svn-id: https://develop.svn.wordpress.org/trunk@20928 602fd350-edb4-49c9-b593-d223f7449a82
Both can slow down the experience.
The alternate cron will issue a redirect which creates more work for the
customizer, but not exit immediately, which means shutdown will be delayed
(see future changeset from koopersmith in #20507 where we check for a token
printed on shutdown to ensure the response came from the customizer).
The update checks could also cause bad data to be sent. In particular, the
currently active theme would be incorrect.
see #20507.
git-svn-id: https://develop.svn.wordpress.org/trunk@20924 602fd350-edb4-49c9-b593-d223f7449a82
Removes script queue check for 'customize-loader' from wp_customize_support_script(), because we may want to check for customize-support on a page without the loader.
git-svn-id: https://develop.svn.wordpress.org/trunk@20918 602fd350-edb4-49c9-b593-d223f7449a82
Now that sections are organized in accordions, group items by size and usage.
Move header/background controls into colors, header image, background image, and title/tagline sections.
git-svn-id: https://develop.svn.wordpress.org/trunk@20912 602fd350-edb4-49c9-b593-d223f7449a82
Instead of fetching default header_textcolor manually, return null to do so automatically.
Improve hex regex.
git-svn-id: https://develop.svn.wordpress.org/trunk@20910 602fd350-edb4-49c9-b593-d223f7449a82
If the custom background default wp-head-callback (_custom_background_cb) is used, we use postMessage for all custom background properties. Otherwise, we use full refreshes.
When using postMessage, the preview recalculates the custom background CSS block, allowing it to omit CSS values when they are not present and fall back on the original CSS.
git-svn-id: https://develop.svn.wordpress.org/trunk@20908 602fd350-edb4-49c9-b593-d223f7449a82
If there is a default color registered, show a 'Default' action rather than a 'Clear' action, as clearing the value would simply return to the default.
Make current_theme_supports() accept a second argument for 'custom-background' requests, the same as get_theme_support(). Missed in earlier changes, see #20249.
fixes#20734, fixes#18041.
git-svn-id: https://develop.svn.wordpress.org/trunk@20901 602fd350-edb4-49c9-b593-d223f7449a82
Add wp_customize_support_script(), to quickly alter the body class based on whether customize is supported.
git-svn-id: https://develop.svn.wordpress.org/trunk@20893 602fd350-edb4-49c9-b593-d223f7449a82
page was about.php?updated, then issue a message welcoming them.
This is to prevent it from being so jolting if you are taken to
the login screen after an update.
In WordPress 3.4, the changes to wp_salt() provide for extra
security, but will cause a log-out for any installs without 8
unique keys and salts in wp-config.php (with some exceptions).
Properly re-issuing cookies, even for the logged in user, is
not easily doable via admin/includes/update-core.php, as that
file is included long after the headers are sent.
see #19599.
git-svn-id: https://develop.svn.wordpress.org/trunk@20887 602fd350-edb4-49c9-b593-d223f7449a82