JSFiddle - React, Tailwind, and code Playground

HTML

<link rel="stylesheet" href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/themes/base/jquery-ui.css">
<div id="test1">
    <img id="logo" src="http://static.jquery.com/files/rocker/images/logo_jquery_215x53.gif" />
</div>
<select id="test">
   <option value="0">Normal</option>
   <option value="1">Pop Up</option>
</select>

JavaScript

$('#test').change(function(){
   if($('#test').val()=='1'){
        $('#test1').dialog();
    }
});

$( "#test1" ).bind( "dialogclose", function(event, ui) {
    $(this).dialog( "destroy" );
    $(this).show();
    $('#test').insertAfter(this);
});