"Untitled"
Bootstrap 4.1.1 Snippet by adarwash2012

<link href="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css"> <script src="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/js/bootstrap.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script> <!------ Include the above in your HEAD tag ----------> <link href="https://fonts.googleapis.com/css?family=Aguafina+Script|Clicker+Script|Dancing+Script|Euphoria+Script|Kaushan+Script|League+Script|Lily+Script+One|Marck+Script|Meie+Script|Nanum+Pen+Script|Pacifico|Petit+Formal+Script|Pinyon+Script|Rouge+Script|Seaweed+Script|Shadows+Into+Light+Two|Vibur" rel="stylesheet"> <!-- Button trigger modal --> <button id='sign_select' type="button" class="btn btn-primary" data-toggle="modal" data-target="#sigs"> Launch demo modal </button> <!-- Modal --> <div class="modal fade" id="sigs" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true"> <div class="modal-dialog" role="document"> <div class="modal-content"> <div class="modal-header"> <h5 class="modal-title" id="exampleModalLabel">Modal title</h5> <button type="button" class="close" data-dismiss="modal" aria-label="Close"> <span aria-hidden="true">×</span> </button> </div> <div class="modal-body"> <ul class="list-group"> <li class="list-group-item" name="Dancing Script"></li> <li class="list-group-item" name="Kaushan Script"></li> <li class="list-group-item" name="Marck Script"></li> <li class="list-group-item" name="Pinyon Script"></li> <li class="list-group-item" name="Nanum Pen Script"></li> <li class="list-group-item" name="Petit Formal Script"></li> <li class="list-group-item" name="Clicker Script"></li> <li class="list-group-item" name="Seaweed Script"></li> <li class="list-group-item" name="Rouge Script"></li> <li class="list-group-item" name="Aguafina Script"></li> <li class="list-group-item" name="Euphoria Script"></li> <li class="list-group-item" name="Lily Script One"></li> <li class="list-group-item" name="League Script"></li> <li class="list-group-item" name="Meie Script"></li> <li class="list-group-item" name="Shadows Into Light Two"></li> <li class="list-group-item" name="Pacifico"></li> <li class="list-group-item" name="Vibur"></li> </ul> </div> <div class="modal-footer"> <button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button> <button type="button" class="btn btn-primary">Save changes</button> </div> </div> </div> </div> <input id="signture" type="text">
$(function() { $('#signture').on('click', function() { $('#signture').show(); $('.modal-body').each(function() { var phrase = ''; $(this).find('li').each(function() { var current = $(this); var font = $(this).attr("name"); var text = $('#signture').val(); $(this).text(text); $(this).css("font-family", font); }); }); }); $( "li" ).hover(function() { $( this ).toggleClass( "active" ) }); $('li').click(function() { $('li').css("background-color","white"); $('li').css("color","black"); $(this).css("background-color","#ffc107"); $(this).css("color","white"); $('#signture').css("font-family", $(this).attr('name')); }); });

Related: See More


Questions / Comments: