mirror of
https://github.com/dataarts/dat.gui.git
synced 2024-12-12 04:08:27 +00:00
29 lines
345 B
JavaScript
29 lines
345 B
JavaScript
/* globals Gui, Polymer */
|
|
|
|
|
|
Gui.register( 'dat-gui-string', function( value ) {
|
|
|
|
return typeof value == 'string';
|
|
|
|
} );
|
|
|
|
Polymer( 'dat-gui-string', {
|
|
|
|
click: function( e ) {
|
|
|
|
this.$.input.select();
|
|
|
|
},
|
|
|
|
keydown: function( e ) {
|
|
|
|
if ( e.keyCode == 13 ) {
|
|
|
|
this.$.input.blur();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} );
|