File tree Expand file tree Collapse file tree 1 file changed +93
-0
lines changed
Expand file tree Collapse file tree 1 file changed +93
-0
lines changed Original file line number Diff line number Diff line change 1+ <!DOCTYPE html>
2+ < html lang =en >
3+ < head >
4+ < title > jQuery Tools standalone demo</ title >
5+
6+ < script src ="../js/jquery-1.6.2.js "> </ script >
7+ < script src ="../../src/toolbox/toolbox.expose.js "> </ script >
8+
9+ < style type ="text/css ">
10+ .wrap {
11+ position : relative;
12+ width : 395px ;
13+ margin : 0 auto;
14+ margin-top : 50px ;
15+ /*border: 1px dotted #cccccc;*/
16+ }
17+
18+ form .expose {
19+ border : 1px outset # ccc ;
20+ background : # fff url ('http://www.tribalmystic.com/tools/img/global/h150.png' ) repeat-x;
21+ padding : 20px ;
22+ margin : 20px 0 ;
23+ text-align : center;
24+ width : 350px ;
25+ -moz-border-radius : 4px ;
26+ -webkit-border-radius : 4px ;
27+ border-radius : 4px ;
28+ }
29+
30+ /* http://www.quirksmode.org/css/forms.html */
31+ label , input {
32+ display : block;
33+ width : 150px ;
34+ float : left;
35+ margin-bottom : 10px ;
36+ }
37+
38+ label {
39+ text-align : right;
40+ width : 75px ;
41+ padding-right : 20px ;
42+ }
43+
44+ br {
45+ clear : left;
46+ }
47+
48+ p {
49+ font-size : 1.4em ;
50+ }
51+ </ style >
52+
53+ </ head >
54+ < body >
55+
56+ < div class ="wrap ">
57+
58+ < form class ="expose ">
59+ < label for ="username "> Username</ label >
60+ < input id ="username " /> < br />
61+ < label for ="password "> Password</ label >
62+ < input id ="password " type ="password " /> < br />
63+ </ form >
64+
65+ < p > Lorem ipsum dolor sit amet, consectetur adipiscing elit. Mauris vel velit sed sapien sollicitudin ultricies ornare ac ipsum</ p >
66+
67+ </ div >
68+ </ body >
69+
70+ < script type ="text/javascript ">
71+ $ ( function ( ) {
72+
73+ // expose the form when it's clicked or cursor is focused
74+ var form = $ ( ".expose" ) . bind ( "click keydown" , function ( ) {
75+
76+ $ ( this ) . expose ( {
77+
78+ // when exposing is done, change form's background color
79+ onLoad : function ( ) {
80+ form . css ( { backgroundColor : '#c7f8ff' } ) ;
81+ } ,
82+
83+ // when "unexposed", return to original background color
84+ onClose : function ( ) {
85+ form . css ( { backgroundColor : '' } ) ;
86+ }
87+ } ) ;
88+ } ) ;
89+
90+ } ) ;
91+ </ script >
92+
93+ </ html >
You can’t perform that action at this time.
0 commit comments