~jstys-z/helioviewer.org/timeline

« back to all changes in this revision

Viewing changes to lib/jquery/jquery.ui-1.7.1/development-bundle/demos/resizable/constrain-area.html

  • Committer: V. Keith Hughitt
  • Date: 2009-03-26 19:20:57 UTC
  • Revision ID: hughitt1@kore-20090326192057-u0x8rf8sf5lmmnwh
nightly build 03-26-2009: Using alpha-channel JPEG 2000 dataset

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<!doctype html>
 
2
<html lang="en">
 
3
<head>
 
4
        <title>jQuery UI Resizable - Constrain resize area</title>
 
5
        <link type="text/css" href="../../themes/base/ui.all.css" rel="stylesheet" />
 
6
        <script type="text/javascript" src="../../jquery-1.3.2.js"></script>
 
7
        <script type="text/javascript" src="../../ui/ui.core.js"></script>
 
8
        <script type="text/javascript" src="../../ui/ui.resizable.js"></script>
 
9
        <link type="text/css" href="../demos.css" rel="stylesheet" />
 
10
        <style type="text/css">
 
11
        #container { width: 300px; height: 300px; }
 
12
        #container h3 { text-align: center; margin: 0; margin-bottom: 10px; }
 
13
        #resizable { background-position: top left; width: 150px; height: 150px; }
 
14
        #resizable, #container { padding: 0.5em; }
 
15
        </style>
 
16
        <script type="text/javascript">
 
17
        $(function() {
 
18
                $("#resizable").resizable({
 
19
                        containment: '#container'
 
20
                });
 
21
        });
 
22
        </script>
 
23
</head>
 
24
<body>
 
25
<div class="demo">
 
26
        
 
27
<div id="container" class="ui-widget-content">
 
28
        <h3 class="ui-widget-header">Containment</h3>
 
29
        <div id="resizable" class="ui-state-active">
 
30
                <h3 class="ui-widget-header">Resizable</h3>
 
31
        </div>
 
32
</div>
 
33
 
 
34
</div><!-- End demo -->
 
35
 
 
36
<div class="demo-description">
 
37
 
 
38
<p>Define the boundaries of the resizable area. Use the <code>containment</code> option to specify a parent DOM element or a jQuery selector, like 'document.'</p>
 
39
 
 
40
</div><!-- End demo-description -->
 
41
</body>
 
42
</html>