Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
<link href="//code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.min.css" rel="stylesheet" type="text/css" />
<script src="//code.jquery.com/jquery-1.11.0.min.js"></script>
<script src="//code.jquery.com/ui/1.11.4/jquery-ui.min.js"></script>
  <meta charset="utf-8">
  <title>JS Bin</title>
</head>
<body>
  <div class="resizable">
    Hello, world!
  </div>
  
  <div class="resizable">
    Hello, world!
  </div>
</body>
</html>
 
.resizable {
  background-color: yellow;
  width: 100px;
  height: 50px;
  margin: 20px
}
.resizable.focus .ui-resizable-handle {
  display: block;
  background-color: blue;
}
.ui-resizable-handle {
  display: none;
}
.ui-resizable-se {
  width: 9px;
  height: 9px;
  right: -5px;
  bottom: -5px;
}
 
$('.resizable').resizable({
  handles: 'ne, se, sw, nw'
});
$('.ui-icon-gripsmall-diagonal-se').removeClass('ui-icon-gripsmall-diagonal-se').removeClass('ui-icon');
$(document).on('click', function(e) {
  $('.resizable').removeClass('focus');
  $resizable = $(e.target).closest('.resizable');
  if ($resizable.length) {
    $resizable.addClass('focus');
  }
});
Output 300px

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
anonymouspro
0viewers