2020 < script src ="../ui/jquery.ui.draggable.js "> </ script >
2121 < script src ="../ui/jquery.ui.droppable.js "> </ script >
2222 < script src ="../ui/jquery.ui.menu.js "> </ script >
23+ < script src ="../ui/jquery.ui.menubar.js "> </ script >
24+ < script src ="../ui/jquery.ui.popup.js "> </ script >
2325 < script src ="../ui/jquery.ui.position.js "> </ script >
2426 < script src ="../ui/jquery.ui.progressbar.js "> </ script >
2527 < script src ="../ui/jquery.ui.resizable.js "> </ script >
111113 < script src ="../ui/i18n/jquery.ui.datepicker-zh-TW.js "> </ script >
112114 < script >
113115 $ ( function ( ) {
114-
116+
115117 $ ( '.left-nav a' ) . click ( function ( ev ) {
116118 window . location . hash = this . href . replace ( / .+ \/ ( [ ^ \/ ] + ) \/ i n d e x \. h t m l / , '$1' ) + '|default' ;
117119 loadPage ( this . href ) ;
118120 $ ( '.left-nav a.selected' ) . removeClass ( 'selected' ) ;
119121 $ ( this ) . addClass ( 'selected' ) ;
120122 ev . preventDefault ( ) ;
121123 } ) ;
122-
124+
123125 if ( window . location . hash ) {
124126 if ( window . location . hash . indexOf ( '|' ) === - 1 ) {
125- window . location . hash += '|default' ;
126- }
127+ window . location . hash += '|default' ;
128+ }
127129 var path = window . location . href . replace ( / ( i n d e x \. h t m l ) ? # / , '' ) ;
128130 path = path . replace ( '\|' , '/' ) + '.html' ;
129131 loadPage ( path ) ;
130- }
132+ }
131133
132- function loadPage ( path ) {
134+ function loadPage ( path ) {
133135 var section = path . replace ( / \/ [ ^ \/ ] + \. h t m l / , '' ) ;
134136 var header = section . replace ( / .+ \/ ( [ ^ \/ ] + ) / , '$1' ) . replace ( / _ / , ' ' ) ;
135-
137+
136138 $ ( 'td.normal div.normal' )
137139 . empty ( )
138140 . append ( '<h4 class="demo-subheader">Functional demo:</h4>' )
148150 $ ( this ) . click ( function ( ) {
149151
150152 resetDemos ( ) ;
151-
153+
152154 $ ( this ) . parents ( 'ul' ) . find ( 'li' ) . removeClass ( 'demo-config-on' ) ;
153155 $ ( this ) . parent ( ) . addClass ( 'demo-config-on' ) ;
154156 $ ( '#demo-notes' ) . fadeOut ( ) ;
167169 $ ( '#demo-config-menu a' ) . each ( function ( ) {
168170 if ( this . href . indexOf ( demo + '.html' ) !== - 1 ) {
169171 $ ( this ) . parents ( 'ul' ) . find ( 'li' ) . removeClass ( 'demo-config-on' ) ;
170- $ ( this ) . parent ( ) . addClass ( 'demo-config-on' ) ;
171- loadDemo ( this . href ) ;
172+ $ ( this ) . parent ( ) . addClass ( 'demo-config-on' ) ;
173+ loadDemo ( this . href ) ;
172174 }
173175 } ) ;
174176 }
184186 . end ( )
185187 . end ( )
186188 ;
187-
189+
188190 resetDemos ( ) ;
189191 }
190-
192+
191193 function loadDemo ( path ) {
192194 var directory = path . match ( / ( [ ^ \/ ] + ) \/ [ ^ \/ \. ] + \. h t m l $ / ) [ 1 ] ;
193195 $ . get ( path , function ( data ) {
207209 $ ( '#demo-link a' ) . attr ( 'href' , path ) ;
208210 updateDemoNotes ( ) ;
209211 updateDemoSource ( source ) ;
210-
212+
211213 if ( / d e f a u l t .h t m l $ / . test ( path ) ) {
212214 $ . get ( "documentation/docs-" + path . match ( / d e m o s \/ ( .+ ) \/ / ) [ 1 ] + ".html" , function ( html ) {
213215 $ ( "#demo-source" ) . after ( html ) ;
241243 $ ( '#demo-notes' ) . show ( ) ;
242244 notes . hide ( ) ;
243245 }
244-
246+
245247 function updateDemoSource ( source ) {
246248 if ( $ ( '#demo-source' ) . length == 0 ) {
247249 $ ( '<div id="demo-source"><a href="#" class="source-closed">View Source</a><div><pre><code></code></pre></div></div>' ) . insertAfter ( '#demo-notes' ) ;
257259
258260 $ ( '#demo-source code' ) . empty ( ) . text ( cleanedSource ) ;
259261 }
260-
262+
261263 function resetDemos ( ) {
262264 $ . datepicker . setDefaults ( $ . extend ( { showMonthAfterYear : false } , $ . datepicker . regional [ '' ] ) ) ;
263- $ ( ".ui-dialog-content" ) . remove ( ) ;
265+ $ ( ".ui-dialog-content" ) . remove ( ) ;
264266 }
265-
267+
266268 } ) ;
267269 </ script >
268270</ head >
285287 < dd > < a href ="datepicker/index.html "> Datepicker</ a > </ dd >
286288 < dd > < a href ="dialog/index.html "> Dialog</ a > </ dd >
287289 < dd > < a href ="menu/index.html "> Menu</ a > </ dd >
290+ < dd > < a href ="menubar/index.html "> Menubar</ a > </ dd >
291+ < dd > < a href ="popup/index.html "> Popup</ a > </ dd >
288292 < dd > < a href ="progressbar/index.html "> Progressbar</ a > </ dd >
289293 < dd > < a href ="slider/index.html "> Slider</ a > </ dd >
290294 < dd > < a href ="spinner/index.html "> Spinner</ a > </ dd >
305309 < dd > < a href ="widget/index.html "> Widget</ a > </ dd >
306310 < dt > About jQuery UI</ dt >
307311 < dd > < a href ="http://jqueryui.com/docs/Getting_Started "> Getting Started</ a > </ dd >
308- < dd > < a href ="http://jqueryui.com/docs/Upgrade_Guide "> Upgrade Guide</ a > </ dd >
312+ < dd > < a href ="http://jqueryui.com/docs/Upgrade_Guide "> Upgrade Guide</ a > </ dd >
309313 < dd > < a href ="http://jqueryui.com/docs/Changelog "> Changelog</ a > </ dd >
310314 < dd > < a href ="http://jqueryui.com/docs/Roadmap "> Roadmap</ a > </ dd >
311315 < dd > < a href ="http://jqueryui.com/docs/Subversion "> Subversion Access</ a > </ dd >
@@ -326,7 +330,7 @@ <h3>Instructions</h3>
326330 < p >
327331 These demos showcase some common uses of each jQuery UI plugin. Simply copy and paste code from the demos to get started. Have fun playing with them.
328332 </ p >
329-
333+
330334 </ div >
331335
332336 </ td >
0 commit comments