[wp-trac] [WordPress Trac] #20879: Customizer: Add keyup events to sync textarea values.
WordPress Trac
wp-trac at lists.automattic.com
Thu Jun 7 16:36:57 UTC 2012
#20879: Customizer: Add keyup events to sync textarea values.
--------------------------+--------------------------
Reporter: koopersmith | Owner: koopersmith
Type: defect (bug) | Status: new
Priority: normal | Milestone: 3.4
Component: Appearance | Version: 3.4
Severity: normal | Resolution:
Keywords: has-patch |
--------------------------+--------------------------
Comment (by koopersmith):
Since we don't have any controls in core with textareas, here's an easy
way to test the patch.
1. Navigate to `yoursite.com/wp-admin/customize.php`
2. Open up your browser's JS console.
3. Drop this code block in the console:
{{{
var textarea = jQuery('<textarea>').appendTo('#customize-theme-controls');
var element = new wp.customize.Element( textarea );
element.bind( function() {
console.log('element changed', arguments);
});
}}}
4. Click inside the new textarea in the sidebar and type some text.
5. Click somewhere outside of the textarea.
With the patch, you should see the value changing in the console as you
type. Without the patch, you'll only see a change when you click out of
the textarea (triggering a `change` event).
--
Ticket URL: <http://core.trac.wordpress.org/ticket/20879#comment:1>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list