Index: trunk/extensions/UsabilityInitiative/UsabilityInitiative.hooks.php |
— | — | @@ -22,18 +22,18 @@ |
23 | 23 | array( 'src' => 'css/vector.collapsibleNav.css', 'version' => 6 ), |
24 | 24 | array( 'src' => 'css/vector.footerCleanup.css', 'version' => 1 ), |
25 | 25 | array( 'src' => 'css/wikiEditor.css', 'version' => 8 ), |
26 | | - array( 'src' => 'css/wikiEditor.dialogs.css', 'version' => 13 ), |
| 26 | + array( 'src' => 'css/wikiEditor.dialogs.css', 'version' => 14 ), |
27 | 27 | array( 'src' => 'css/wikiEditor.preview.css', 'version' => 1 ), |
28 | 28 | array( 'src' => 'css/wikiEditor.toc.css', 'version' => 28 ), |
29 | 29 | array( 'src' => 'css/wikiEditor.toolbar.css', 'version' => 10 ), |
30 | 30 | array( 'src' => 'css/vector/jquery-ui-1.7.2.css', 'version' => '1.7.2y' ), |
31 | 31 | ), |
32 | 32 | 'combined' => array( |
33 | | - array( 'src' => 'css/combined.css', 'version' => 55 ), |
| 33 | + array( 'src' => 'css/combined.css', 'version' => 56 ), |
34 | 34 | array( 'src' => 'css/vector/jquery-ui-1.7.2.css', 'version' => '1.7.2y' ), |
35 | 35 | ), |
36 | 36 | 'minified' => array( |
37 | | - array( 'src' => 'css/combined.min.css', 'version' => 55 ), |
| 37 | + array( 'src' => 'css/combined.min.css', 'version' => 56 ), |
38 | 38 | array( 'src' => 'css/vector/jquery-ui-1.7.2.css', 'version' => '1.7.2y' ), |
39 | 39 | ), |
40 | 40 | ) |
— | — | @@ -155,7 +155,7 @@ |
156 | 156 | array( |
157 | 157 | 'src' => 'js/plugins/jquery.wikiEditor.toc.js', |
158 | 158 | 'class' => 'j.wikiEditor.modules.toc', |
159 | | - 'version' => 71 |
| 159 | + 'version' => 72 |
160 | 160 | ), |
161 | 161 | array( |
162 | 162 | 'src' => 'js/plugins/jquery.wikiEditor.preview.js', |
— | — | @@ -173,10 +173,10 @@ |
174 | 174 | 'version' => 1 ), |
175 | 175 | ), |
176 | 176 | 'combined' => array( |
177 | | - array( 'src' => 'js/plugins.combined.js', 'version' => 177 ), |
| 177 | + array( 'src' => 'js/plugins.combined.js', 'version' => 178 ), |
178 | 178 | ), |
179 | 179 | 'minified' => array( |
180 | | - array( 'src' => 'js/plugins.combined.min.js', 'version' => 177 ), |
| 180 | + array( 'src' => 'js/plugins.combined.min.js', 'version' => 178 ), |
181 | 181 | ), |
182 | 182 | ), |
183 | 183 | ); |
Index: trunk/extensions/UsabilityInitiative/css/wikiEditor.dialogs.css |
— | — | @@ -26,7 +26,7 @@ |
27 | 27 | |
28 | 28 | |
29 | 29 | .ui-dialog .ui-dialog-titlebar { |
30 | | - padding: 0.75em 20px !important; |
| 30 | + padding: 0.9em 1.4em 0.6em !important; |
31 | 31 | } |
32 | 32 | .ui-widget table td { |
33 | 33 | padding: 0 !important; |
— | — | @@ -65,17 +65,30 @@ |
66 | 66 | } |
67 | 67 | .ui-dialog .ui-dialog-buttonpane { |
68 | 68 | margin-top: 0 !important; |
69 | | - padding:0.3em 1em 0.5em 1em !important; |
| 69 | + padding:0.3em 1.4em 0.5em 1.4em !important; |
70 | 70 | } |
71 | 71 | |
72 | 72 | .ui-dialog-content fieldset{ |
73 | 73 | border: none !important; |
74 | 74 | margin: 0 !important; |
| 75 | + padding: 0 !important; |
75 | 76 | } |
76 | | - |
77 | 77 | .ui-widget-header { |
78 | 78 | border-bottom:1px solid #6bc8f3 !important; |
79 | 79 | } |
| 80 | +.ui-dialog-content input[type=text] { |
| 81 | + -moz-box-sizing: border-box; |
| 82 | + -ms-box-sizing: border-box; |
| 83 | + -webkit-box-sizing: border-box; |
| 84 | + -khtml-box-sizing: border-box; |
| 85 | +} |
| 86 | +.ui-dialog-content input[type="radio"], |
| 87 | +.ui-dialog-content input[type="checkbox"] { |
| 88 | + margin-left: 0; |
| 89 | +} |
| 90 | +.ui-dialog .ui-dialog-titlebar-close { |
| 91 | + right: 0.9em !important; |
| 92 | +} |
80 | 93 | .wikieditor-toolbar-field-wrapper { |
81 | 94 | padding: 0 0 25px 0; |
82 | 95 | } |
— | — | @@ -86,14 +99,15 @@ |
87 | 100 | border: none !important; |
88 | 101 | } |
89 | 102 | /* Table Dialog */ |
| 103 | + |
90 | 104 | #wikieditor-toolbar-table-dialog fieldset { |
91 | | - width: 200px; |
92 | | - padding: 30px 0 0; |
| 105 | + width: 218px; |
| 106 | + padding: 0; |
93 | 107 | float: left; |
94 | 108 | } |
95 | | -.wikieditor-toolbar-table-preview-wrapper { |
96 | | - padding: 30px 0 0; |
97 | | - width: 280px; |
| 109 | +#wikieditor-toolbar-table-dialog .wikieditor-toolbar-table-preview-wrapper { |
| 110 | + width: 330px; |
| 111 | + padding: 0; |
98 | 112 | float: right; |
99 | 113 | } |
100 | 114 | .wikieditor-toolbar-table-preview-content * { |
— | — | @@ -104,20 +118,24 @@ |
105 | 119 | } |
106 | 120 | .ui-widget .wikieditor-toolbar-table-preview-content table td { |
107 | 121 | padding: 10px 4px !important; |
| 122 | + height: auto !important; |
108 | 123 | } |
109 | 124 | .ui-widget .wikieditor-toolbar-table-preview-content table th { |
110 | 125 | padding: 7px 3px !important; |
111 | 126 | } |
112 | | -.wikieditor-toolbar-table-dimension-fields { |
113 | | - overflow: visible; |
114 | | - width: 100%; |
115 | | - margin: 0 4px; |
116 | | -} |
117 | 127 | .wikieditor-toolbar-table-dimension-fields .wikieditor-toolbar-field-wrapper { |
118 | 128 | float: left; |
119 | 129 | margin-right: 20px; |
120 | 130 | vertical-align: bottom; |
121 | 131 | } |
| 132 | +.ui-dialog .ui-dialog-content { |
| 133 | + padding: 30px 20px 0 !important; |
| 134 | +} |
| 135 | +.wikieditor-toolbar-dialog-wrapper { |
| 136 | + width: 100%; |
| 137 | +} |
| 138 | +/* REPLACE Dialog */ |
| 139 | + |
122 | 140 | /* RTL Changes */ |
123 | 141 | body.rtl .ui-dialog .ui-dialog-buttonpane button { |
124 | 142 | float: left; |
— | — | @@ -129,4 +147,28 @@ |
130 | 148 | } |
131 | 149 | body.rtl .ui-dialog .ui-dialog-title { |
132 | 150 | float:right; |
133 | | -} |
\ No newline at end of file |
| 151 | +} |
| 152 | +/* Self Clearing Floats */ |
| 153 | +.wikieditor-toolbar-table-dimension-fields:after, |
| 154 | +.wikieditor-toolbar-dialog-wrapper:after { |
| 155 | + visibility: hidden; |
| 156 | + display: block; |
| 157 | + font-size: 0; |
| 158 | + content: " "; |
| 159 | + clear: both; |
| 160 | + height: 0; |
| 161 | +} |
| 162 | +.wikieditor-toolbar-table-dimension-fields, |
| 163 | +.wikieditor-toolbar-dialog-wrapper { |
| 164 | + display: inline-table; |
| 165 | +} |
| 166 | +/* Hides from IE-mac \*/ |
| 167 | +* html .wikieditor-toolbar-table-dimension-fields, |
| 168 | +* html .wikieditor-toolbar-dialog-wrapper { |
| 169 | + height: 1%; |
| 170 | +} |
| 171 | +.wikieditor-toolbar-table-dimension-fields, |
| 172 | +.wikieditor-toolbar-dialog-wrapper { |
| 173 | + display: block; |
| 174 | +} |
| 175 | +/* End hide from IE-mac */ |
\ No newline at end of file |
Index: trunk/extensions/UsabilityInitiative/css/combined.css |
— | — | @@ -235,7 +235,7 @@ |
236 | 236 | |
237 | 237 | |
238 | 238 | .ui-dialog .ui-dialog-titlebar { |
239 | | - padding: 0.75em 20px !important; |
| 239 | + padding: 0.9em 1.4em 0.6em !important; |
240 | 240 | } |
241 | 241 | .ui-widget table td { |
242 | 242 | padding: 0 !important; |
— | — | @@ -274,17 +274,30 @@ |
275 | 275 | } |
276 | 276 | .ui-dialog .ui-dialog-buttonpane { |
277 | 277 | margin-top: 0 !important; |
278 | | - padding:0.3em 1em 0.5em 1em !important; |
| 278 | + padding:0.3em 1.4em 0.5em 1.4em !important; |
279 | 279 | } |
280 | 280 | |
281 | 281 | .ui-dialog-content fieldset{ |
282 | 282 | border: none !important; |
283 | 283 | margin: 0 !important; |
| 284 | + padding: 0 !important; |
284 | 285 | } |
285 | | - |
286 | 286 | .ui-widget-header { |
287 | 287 | border-bottom:1px solid #6bc8f3 !important; |
288 | 288 | } |
| 289 | +.ui-dialog-content input[type=text] { |
| 290 | + -moz-box-sizing: border-box; |
| 291 | + -ms-box-sizing: border-box; |
| 292 | + -webkit-box-sizing: border-box; |
| 293 | + -khtml-box-sizing: border-box; |
| 294 | +} |
| 295 | +.ui-dialog-content input[type="radio"], |
| 296 | +.ui-dialog-content input[type="checkbox"] { |
| 297 | + margin-left: 0; |
| 298 | +} |
| 299 | +.ui-dialog .ui-dialog-titlebar-close { |
| 300 | + right: 0.9em !important; |
| 301 | +} |
289 | 302 | .wikieditor-toolbar-field-wrapper { |
290 | 303 | padding: 0 0 25px 0; |
291 | 304 | } |
— | — | @@ -295,14 +308,15 @@ |
296 | 309 | border: none !important; |
297 | 310 | } |
298 | 311 | /* Table Dialog */ |
| 312 | + |
299 | 313 | #wikieditor-toolbar-table-dialog fieldset { |
300 | | - width: 200px; |
301 | | - padding: 30px 0 0; |
| 314 | + width: 218px; |
| 315 | + padding: 0; |
302 | 316 | float: left; |
303 | 317 | } |
304 | | -.wikieditor-toolbar-table-preview-wrapper { |
305 | | - padding: 30px 0 0; |
306 | | - width: 280px; |
| 318 | +#wikieditor-toolbar-table-dialog .wikieditor-toolbar-table-preview-wrapper { |
| 319 | + width: 330px; |
| 320 | + padding: 0; |
307 | 321 | float: right; |
308 | 322 | } |
309 | 323 | .wikieditor-toolbar-table-preview-content * { |
— | — | @@ -313,20 +327,24 @@ |
314 | 328 | } |
315 | 329 | .ui-widget .wikieditor-toolbar-table-preview-content table td { |
316 | 330 | padding: 10px 4px !important; |
| 331 | + height: auto !important; |
317 | 332 | } |
318 | 333 | .ui-widget .wikieditor-toolbar-table-preview-content table th { |
319 | 334 | padding: 7px 3px !important; |
320 | 335 | } |
321 | | -.wikieditor-toolbar-table-dimension-fields { |
322 | | - overflow: visible; |
323 | | - width: 100%; |
324 | | - margin: 0 4px; |
325 | | -} |
326 | 336 | .wikieditor-toolbar-table-dimension-fields .wikieditor-toolbar-field-wrapper { |
327 | 337 | float: left; |
328 | 338 | margin-right: 20px; |
329 | 339 | vertical-align: bottom; |
330 | 340 | } |
| 341 | +.ui-dialog .ui-dialog-content { |
| 342 | + padding: 30px 20px 0 !important; |
| 343 | +} |
| 344 | +.wikieditor-toolbar-dialog-wrapper { |
| 345 | + width: 100%; |
| 346 | +} |
| 347 | +/* REPLACE Dialog */ |
| 348 | + |
331 | 349 | /* RTL Changes */ |
332 | 350 | body.rtl .ui-dialog .ui-dialog-buttonpane button { |
333 | 351 | float: left; |
— | — | @@ -338,7 +356,31 @@ |
339 | 357 | } |
340 | 358 | body.rtl .ui-dialog .ui-dialog-title { |
341 | 359 | float:right; |
342 | | -}/* wikiEditor toc module */ |
| 360 | +} |
| 361 | +/* Self Clearing Floats */ |
| 362 | +.wikieditor-toolbar-table-dimension-fields:after, |
| 363 | +.wikieditor-toolbar-dialog-wrapper:after { |
| 364 | + visibility: hidden; |
| 365 | + display: block; |
| 366 | + font-size: 0; |
| 367 | + content: " "; |
| 368 | + clear: both; |
| 369 | + height: 0; |
| 370 | +} |
| 371 | +.wikieditor-toolbar-table-dimension-fields, |
| 372 | +.wikieditor-toolbar-dialog-wrapper { |
| 373 | + display: inline-table; |
| 374 | +} |
| 375 | +/* Hides from IE-mac \*/ |
| 376 | +* html .wikieditor-toolbar-table-dimension-fields, |
| 377 | +* html .wikieditor-toolbar-dialog-wrapper { |
| 378 | + height: 1%; |
| 379 | +} |
| 380 | +.wikieditor-toolbar-table-dimension-fields, |
| 381 | +.wikieditor-toolbar-dialog-wrapper { |
| 382 | + display: block; |
| 383 | +} |
| 384 | +/* End hide from IE-mac *//* wikiEditor toc module */ |
343 | 385 | .wikiEditor-ui-toc { |
344 | 386 | /* height and width are set dynamically */ |
345 | 387 | /*float: right;*/ |
Index: trunk/extensions/UsabilityInitiative/css/combined.min.css |
— | — | @@ -217,7 +217,7 @@ |
218 | 218 | padding:2px 1px; |
219 | 219 | } |
220 | 220 | .ui-dialog .ui-dialog-titlebar{ |
221 | | -padding:0.75em 20px !important; |
| 221 | +padding:0.9em 1.4em 0.6em !important; |
222 | 222 | } |
223 | 223 | .ui-widget table td{ |
224 | 224 | padding:0 !important; |
— | — | @@ -253,15 +253,29 @@ |
254 | 254 | } |
255 | 255 | .ui-dialog .ui-dialog-buttonpane{ |
256 | 256 | margin-top:0 !important; |
257 | | -padding:0.3em 1em 0.5em 1em !important; |
| 257 | +padding:0.3em 1.4em 0.5em 1.4em !important; |
258 | 258 | } |
259 | 259 | .ui-dialog-content fieldset{ |
260 | 260 | border:none !important; |
261 | 261 | margin:0 !important; |
| 262 | +padding:0 !important; |
262 | 263 | } |
263 | 264 | .ui-widget-header{ |
264 | 265 | border-bottom:1px solid #6bc8f3 !important; |
265 | 266 | } |
| 267 | +.ui-dialog-content input[type=text]{ |
| 268 | +-moz-box-sizing:border-box; |
| 269 | +-ms-box-sizing:border-box; |
| 270 | +-webkit-box-sizing:border-box; |
| 271 | +-khtml-box-sizing:border-box; |
| 272 | +} |
| 273 | +.ui-dialog-content input[type="radio"], |
| 274 | +.ui-dialog-content input[type="checkbox"]{ |
| 275 | +margin-left:0; |
| 276 | +} |
| 277 | +.ui-dialog .ui-dialog-titlebar-close{ |
| 278 | +right:0.9em !important; |
| 279 | +} |
266 | 280 | .wikieditor-toolbar-field-wrapper{ |
267 | 281 | padding:0 0 25px 0; |
268 | 282 | } |
— | — | @@ -272,13 +286,13 @@ |
273 | 287 | border:none !important; |
274 | 288 | } |
275 | 289 | #wikieditor-toolbar-table-dialog fieldset{ |
276 | | -width:200px; |
277 | | -padding:30px 0 0; |
| 290 | +width:218px; |
| 291 | +padding:0; |
278 | 292 | float:left; |
279 | 293 | } |
280 | | -.wikieditor-toolbar-table-preview-wrapper{ |
281 | | -padding:30px 0 0; |
282 | | -width:280px; |
| 294 | +#wikieditor-toolbar-table-dialog .wikieditor-toolbar-table-preview-wrapper{ |
| 295 | +width:330px; |
| 296 | +padding:0; |
283 | 297 | float:right; |
284 | 298 | } |
285 | 299 | .wikieditor-toolbar-table-preview-content *{ |
— | — | @@ -289,20 +303,22 @@ |
290 | 304 | } |
291 | 305 | .ui-widget .wikieditor-toolbar-table-preview-content table td{ |
292 | 306 | padding:10px 4px !important; |
| 307 | +height:auto !important; |
293 | 308 | } |
294 | 309 | .ui-widget .wikieditor-toolbar-table-preview-content table th{ |
295 | 310 | padding:7px 3px !important; |
296 | 311 | } |
297 | | -.wikieditor-toolbar-table-dimension-fields{ |
298 | | -overflow:visible; |
299 | | -width:100%; |
300 | | -margin:0 4px; |
301 | | -} |
302 | 312 | .wikieditor-toolbar-table-dimension-fields .wikieditor-toolbar-field-wrapper{ |
303 | 313 | float:left; |
304 | 314 | margin-right:20px; |
305 | 315 | vertical-align:bottom; |
306 | 316 | } |
| 317 | +.ui-dialog .ui-dialog-content{ |
| 318 | +padding:30px 20px 0 !important; |
| 319 | +} |
| 320 | +.wikieditor-toolbar-dialog-wrapper{ |
| 321 | +width:100%; |
| 322 | +} |
307 | 323 | body.rtl .ui-dialog .ui-dialog-buttonpane button{ |
308 | 324 | float:left; |
309 | 325 | margin:0.5em 0.4 0.5em 0em !important; |
— | — | @@ -314,6 +330,27 @@ |
315 | 331 | body.rtl .ui-dialog .ui-dialog-title{ |
316 | 332 | float:right; |
317 | 333 | } |
| 334 | +.wikieditor-toolbar-table-dimension-fields:after, |
| 335 | +.wikieditor-toolbar-dialog-wrapper:after{ |
| 336 | +visibility:hidden; |
| 337 | +display:block; |
| 338 | +font-size:0; |
| 339 | +content:" "; |
| 340 | +clear:both; |
| 341 | +height:0; |
| 342 | +} |
| 343 | +.wikieditor-toolbar-table-dimension-fields, |
| 344 | +.wikieditor-toolbar-dialog-wrapper{ |
| 345 | +display:inline-table; |
| 346 | +} |
| 347 | +* html .wikieditor-toolbar-table-dimension-fields, |
| 348 | +* html .wikieditor-toolbar-dialog-wrapper{ |
| 349 | +height:1%; |
| 350 | +} |
| 351 | +.wikieditor-toolbar-table-dimension-fields, |
| 352 | +.wikieditor-toolbar-dialog-wrapper{ |
| 353 | +display:block; |
| 354 | +} |
318 | 355 | .wikiEditor-ui-toc{ |
319 | 356 | padding:0; |
320 | 357 | overflow:auto; |
Index: trunk/extensions/UsabilityInitiative/WikiEditor/WikiEditor.hooks.php |
— | — | @@ -35,7 +35,7 @@ |
36 | 36 | array( |
37 | 37 | 'src' => 'Modules/Toolbar/Toolbar.js', |
38 | 38 | 'class' => 'wikiEditor.config.toolbar', |
39 | | - 'version' => 32 |
| 39 | + 'version' => 33 |
40 | 40 | ), |
41 | 41 | array( |
42 | 42 | 'src' => 'Modules/TemplateEditor/TemplateEditor.js', |
— | — | @@ -44,10 +44,10 @@ |
45 | 45 | ), |
46 | 46 | ), |
47 | 47 | 'combined' => array( |
48 | | - array( 'src' => 'WikiEditor.combined.js', 'version' => 34 ), |
| 48 | + array( 'src' => 'WikiEditor.combined.js', 'version' => 35 ), |
49 | 49 | ), |
50 | 50 | 'minified' => array( |
51 | | - array( 'src' => 'WikiEditor.combined.min.js', 'version' => 34 ), |
| 51 | + array( 'src' => 'WikiEditor.combined.min.js', 'version' => 35 ), |
52 | 52 | ), |
53 | 53 | ); |
54 | 54 | static $messages = array( |
Index: trunk/extensions/UsabilityInitiative/WikiEditor/WikiEditor.combined.js |
— | — | @@ -1556,6 +1556,7 @@ |
1557 | 1557 | id: 'wikieditor-toolbar-table-dialog', |
1558 | 1558 | // FIXME: Localize 'x'? |
1559 | 1559 | html: '\ |
| 1560 | + <div class="wikieditor-toolbar-dialog-wrapper">\ |
1560 | 1561 | <fieldset><div class="wikieditor-toolbar-table-form">\ |
1561 | 1562 | <div class="wikieditor-toolbar-field-wrapper">\ |
1562 | 1563 | <input type="checkbox" id="wikieditor-toolbar-table-dimensions-header" checked />\ |
— | — | @@ -1610,7 +1611,7 @@ |
1611 | 1612 | </tr>\ |
1612 | 1613 | </table>\ |
1613 | 1614 | </div>\ |
1614 | | - </div>', |
| 1615 | + </div></div>', |
1615 | 1616 | init: function() { |
1616 | 1617 | $j(this).find( '[rel]' ).each( function() { |
1617 | 1618 | $j(this).text( gM( $j(this).attr( 'rel' ) ) ); |
— | — | @@ -1662,7 +1663,7 @@ |
1663 | 1664 | }, |
1664 | 1665 | dialog: { |
1665 | 1666 | resizable: false, |
1666 | | - width: 500, |
| 1667 | + width: 590, |
1667 | 1668 | buttons: { |
1668 | 1669 | 'wikieditor-toolbar-tool-table-insert': function() { |
1669 | 1670 | var rowsVal = $j( '#wikieditor-toolbar-table-dimensions-rows' ).val(); |
Index: trunk/extensions/UsabilityInitiative/WikiEditor/WikiEditor.combined.min.js |
— | — | @@ -72,6 +72,7 @@ |
73 | 73 | $j('#wikieditor-toolbar-link-'+type).attr('checked','checked');} |
74 | 74 | $j('#wikieditor-toolbar-link-int-text').data('untouched',$j('#wikieditor-toolbar-link-int-text').val()==$j('#wikieditor-toolbar-link-int-target').val()||$j('#wikieditor-toolbar-link-int-text').hasClass('wikieditor-toolbar-dialog-hint'));$j('#wikieditor-toolbar-link-int-target').suggestions();$j('#wikieditor-toolbar-link-int-text, #wikiedit-toolbar-link-int-target').each(function(){if($j(this).val()=='') |
75 | 75 | $j(this).parent().find('label').show();});if(!($j(this).data('dialogkeypressset'))){$j(this).data('dialogkeypressset',true);$j(this).closest('.ui-dialog').keypress(function(e){if((e.keyCode||e.which)==13){var button=$j(this).data('dialogaction')||$j(this).find('button:first');button.click();e.preventDefault();}});$j(this).closest('.ui-dialog').find('button').focus(function(){$j(this).closest('.ui-dialog').data('dialogaction',this);});}}}},'insert-table':{titleMsg:'wikieditor-toolbar-tool-table-title',id:'wikieditor-toolbar-table-dialog',html:'\ |
| 76 | + <div class="wikieditor-toolbar-dialog-wrapper">\ |
76 | 77 | <fieldset><div class="wikieditor-toolbar-table-form">\ |
77 | 78 | <div class="wikieditor-toolbar-field-wrapper">\ |
78 | 79 | <input type="checkbox" id="wikieditor-toolbar-table-dimensions-header" checked />\ |
— | — | @@ -126,9 +127,9 @@ |
127 | 128 | </tr>\ |
128 | 129 | </table>\ |
129 | 130 | </div>\ |
130 | | - </div>',init:function(){$j(this).find('[rel]').each(function(){$j(this).text(gM($j(this).attr('rel')));});$j('#wikieditor-toolbar-table-dimensions-rows').val(4);$j('#wikieditor-toolbar-table-dimensions-columns').val(3);$j('#wikieditor-toolbar-table-wikitable').click(function(){$j('.wikieditor-toolbar-table-preview').toggleClass('wikitable');});$j('#wikieditor-toolbar-table-preview').clone().attr('id','wikieditor-toolbar-table-preview2').addClass('sortable').insertAfter($j('#wikieditor-toolbar-table-preview')).hide();if(typeof ts_makeSortable=='function') |
| 131 | + </div></div>',init:function(){$j(this).find('[rel]').each(function(){$j(this).text(gM($j(this).attr('rel')));});$j('#wikieditor-toolbar-table-dimensions-rows').val(4);$j('#wikieditor-toolbar-table-dimensions-columns').val(3);$j('#wikieditor-toolbar-table-wikitable').click(function(){$j('.wikieditor-toolbar-table-preview').toggleClass('wikitable');});$j('#wikieditor-toolbar-table-preview').clone().attr('id','wikieditor-toolbar-table-preview2').addClass('sortable').insertAfter($j('#wikieditor-toolbar-table-preview')).hide();if(typeof ts_makeSortable=='function') |
131 | 132 | ts_makeSortable($j('#wikieditor-toolbar-table-preview2').get(0));$j('#wikieditor-toolbar-table-sortable').click(function(){$j('#wikieditor-toolbar-table-preview').hide().attr('id','wikieditor-toolbar-table-preview3');$j('#wikieditor-toolbar-table-preview2').attr('id','wikieditor-toolbar-table-preview').show();$j('#wikieditor-toolbar-table-preview3').attr('id','wikieditor-toolbar-table-preview2');});$j('#wikieditor-toolbar-table-dimensions-header').click(function(){var headerHTML=$j('.wikieditor-toolbar-table-preview-header').html();var hiddenHTML=$j('.wikieditor-toolbar-table-preview-hidden').html();$j('.wikieditor-toolbar-table-preview-header').html(hiddenHTML);$j('.wikieditor-toolbar-table-preview-hidden').html(headerHTML);if(typeof ts_makeSortable=='function') |
132 | | -ts_makeSortable($j('#wikieditor-toolbar-table-preview, #wikieditor-toolbar-table-preview2').filter('.sortable').get(0));});},dialog:{resizable:false,width:500,buttons:{'wikieditor-toolbar-tool-table-insert':function(){var rowsVal=$j('#wikieditor-toolbar-table-dimensions-rows').val();var colsVal=$j('#wikieditor-toolbar-table-dimensions-columns').val();var rows=parseInt(rowsVal,10);var cols=parseInt(colsVal,10);var header=Math.min(1,$j('#wikieditor-toolbar-table-dimensions-header:checked').size());if(isNaN(rows)||isNaN(cols)||rows!=rowsVal||cols!=colsVal){alert(gM('wikieditor-toolbar-tool-table-invalidnumber'));return;} |
| 133 | +ts_makeSortable($j('#wikieditor-toolbar-table-preview, #wikieditor-toolbar-table-preview2').filter('.sortable').get(0));});},dialog:{resizable:false,width:590,buttons:{'wikieditor-toolbar-tool-table-insert':function(){var rowsVal=$j('#wikieditor-toolbar-table-dimensions-rows').val();var colsVal=$j('#wikieditor-toolbar-table-dimensions-columns').val();var rows=parseInt(rowsVal,10);var cols=parseInt(colsVal,10);var header=Math.min(1,$j('#wikieditor-toolbar-table-dimensions-header:checked').size());if(isNaN(rows)||isNaN(cols)||rows!=rowsVal||cols!=colsVal){alert(gM('wikieditor-toolbar-tool-table-invalidnumber'));return;} |
133 | 134 | if(rows+header==0||cols==0){alert(gM('wikieditor-toolbar-tool-table-zero'));return;} |
134 | 135 | if(rows*cols>1000){alert(gM('wikieditor-toolbar-tool-table-toomany',1000));return;} |
135 | 136 | var headerText=gM('wikieditor-toolbar-tool-table-example-header');var normalText=gM('wikieditor-toolbar-tool-table-example');var table="";for(var r=0;r<rows+header;r++){table+="|-\n";for(var c=0;c<cols;c++){var isHeader=(r+1==header);var delim=isHeader?'!':'|';if(c>0){delim+=delim;} |
Index: trunk/extensions/UsabilityInitiative/WikiEditor/Modules/Toolbar/Toolbar.js |
— | — | @@ -1475,6 +1475,7 @@ |
1476 | 1476 | id: 'wikieditor-toolbar-table-dialog', |
1477 | 1477 | // FIXME: Localize 'x'? |
1478 | 1478 | html: '\ |
| 1479 | + <div class="wikieditor-toolbar-dialog-wrapper">\ |
1479 | 1480 | <fieldset><div class="wikieditor-toolbar-table-form">\ |
1480 | 1481 | <div class="wikieditor-toolbar-field-wrapper">\ |
1481 | 1482 | <input type="checkbox" id="wikieditor-toolbar-table-dimensions-header" checked />\ |
— | — | @@ -1529,7 +1530,7 @@ |
1530 | 1531 | </tr>\ |
1531 | 1532 | </table>\ |
1532 | 1533 | </div>\ |
1533 | | - </div>', |
| 1534 | + </div></div>', |
1534 | 1535 | init: function() { |
1535 | 1536 | $j(this).find( '[rel]' ).each( function() { |
1536 | 1537 | $j(this).text( gM( $j(this).attr( 'rel' ) ) ); |
— | — | @@ -1581,7 +1582,7 @@ |
1582 | 1583 | }, |
1583 | 1584 | dialog: { |
1584 | 1585 | resizable: false, |
1585 | | - width: 500, |
| 1586 | + width: 590, |
1586 | 1587 | buttons: { |
1587 | 1588 | 'wikieditor-toolbar-tool-table-insert': function() { |
1588 | 1589 | var rowsVal = $j( '#wikieditor-toolbar-table-dimensions-rows' ).val(); |
Index: trunk/extensions/UsabilityInitiative/js/plugins/jquery.wikiEditor.toc.js |
— | — | @@ -62,10 +62,13 @@ |
63 | 63 | context.modules.toc.$toc.find( 'div' ).autoEllipsis( { 'position': 'right', 'tooltip': true, 'restoreText': true } ); |
64 | 64 | } |
65 | 65 | // reset the height of the TOC |
66 | | - context.modules.toc.$toc.height( |
67 | | - context.$ui.find( '.wikiEditor-ui-left' ).height() - |
68 | | - context.$ui.find( '.tab-toc' ).outerHeight() |
69 | | - ); |
| 66 | + if ( !context.modules.toc.$toc.data( 'collapsed' ) ){ |
| 67 | + context.modules.toc.$toc.height( |
| 68 | + context.$ui.find( '.wikiEditor-ui-left' ).height() - |
| 69 | + context.$ui.find( '.tab-toc' ).outerHeight() |
| 70 | + ); |
| 71 | + } |
| 72 | + |
70 | 73 | // store the width of the view for comparison on next resize |
71 | 74 | context.modules.toc.$toc.data( 'previousWidth', context.$wikitext.width() ); |
72 | 75 | }, |
Index: trunk/extensions/UsabilityInitiative/js/plugins.combined.js |
— | — | @@ -8704,10 +8704,13 @@ |
8705 | 8705 | context.modules.toc.$toc.find( 'div' ).autoEllipsis( { 'position': 'right', 'tooltip': true, 'restoreText': true } ); |
8706 | 8706 | } |
8707 | 8707 | // reset the height of the TOC |
8708 | | - context.modules.toc.$toc.height( |
8709 | | - context.$ui.find( '.wikiEditor-ui-left' ).height() - |
8710 | | - context.$ui.find( '.tab-toc' ).outerHeight() |
8711 | | - ); |
| 8708 | + if ( !context.modules.toc.$toc.data( 'collapsed' ) ){ |
| 8709 | + context.modules.toc.$toc.height( |
| 8710 | + context.$ui.find( '.wikiEditor-ui-left' ).height() - |
| 8711 | + context.$ui.find( '.tab-toc' ).outerHeight() |
| 8712 | + ); |
| 8713 | + } |
| 8714 | + |
8712 | 8715 | // store the width of the view for comparison on next resize |
8713 | 8716 | context.modules.toc.$toc.data( 'previousWidth', context.$wikitext.width() ); |
8714 | 8717 | }, |
Index: trunk/extensions/UsabilityInitiative/js/plugins.combined.min.js |
— | — | @@ -581,8 +581,9 @@ |
582 | 582 | ranges.push(new Range(valueEndIndex,wikitext.length));this.ranges=ranges;this.wikitext=wikitext;this.params=params;this.paramsByName=paramsByName;this.templateNameIndex=templateNameIndex;}}};})(jQuery);(function($){$.wikiEditor.modules.toc={cfg:{defaultWidth:'166px',minimumWidth:'70px',textMinimumWidth:'450px',rtl:false},api:{},evt:{change:function(context,event){$.wikiEditor.modules.toc.fn.update(context);},ready:function(context,event){$.wikiEditor.modules.toc.fn.build(context);context.$content.parent().blur(function(){var context=event.data.context;$.wikiEditor.modules.toc.fn.unhighlight(context);});$.wikiEditor.modules.toc.evt.resize(context);},resize:function(context,event){var availableWidth=context.$wikitext.width()-parseFloat($.wikiEditor.modules.toc.cfg.textMinimumWidth),totalMinWidth=parseFloat($.wikiEditor.modules.toc.cfg.minimumWidth)+ |
583 | 583 | parseFloat($.wikiEditor.modules.toc.cfg.textMinimumWidth);context.$ui.find('.wikiEditor-ui-right').resizable('option','maxWidth',availableWidth);if(context.modules.toc.$toc.data('positionMode')!='disabled'&&context.$wikitext.width()<totalMinWidth){$.wikiEditor.modules.toc.fn.disable(context);}else if(context.modules.toc.$toc.data('positionMode')=='disabled'&&context.$wikitext.width()>totalMinWidth){$.wikiEditor.modules.toc.fn.enable(context);}else if(context.modules.toc.$toc.data('positionMode')=='regular'&&context.$ui.find('.wikiEditor-ui-right').width()>availableWidth){$.wikiEditor.modules.toc.fn.switchLayout(context);}else if(context.modules.toc.$toc.data('positionMode')=='goofy'&&context.modules.toc.$toc.data('previousWidth')<context.$wikitext.width()){$.wikiEditor.modules.toc.fn.switchLayout(context);} |
584 | 584 | if(context.modules.toc.$toc.data('positionMode')=='goofy'){context.modules.toc.$toc.find('div').autoEllipsis({'position':'right','tooltip':true,'restoreText':true});} |
585 | | -context.modules.toc.$toc.height(context.$ui.find('.wikiEditor-ui-left').height()- |
586 | | -context.$ui.find('.tab-toc').outerHeight());context.modules.toc.$toc.data('previousWidth',context.$wikitext.width());},mark:function(context,event){var markers=context.modules.highlight.markers;var tokenArray=context.modules.highlight.tokenArray;var outline=context.data.outline=[];var h=0;for(var i=0;i<tokenArray.length;i++){if(tokenArray[i].label!='TOC_HEADER'){continue;} |
| 585 | +if(!context.modules.toc.$toc.data('collapsed')){context.modules.toc.$toc.height(context.$ui.find('.wikiEditor-ui-left').height()- |
| 586 | +context.$ui.find('.tab-toc').outerHeight());} |
| 587 | +context.modules.toc.$toc.data('previousWidth',context.$wikitext.width());},mark:function(context,event){var markers=context.modules.highlight.markers;var tokenArray=context.modules.highlight.tokenArray;var outline=context.data.outline=[];var h=0;for(var i=0;i<tokenArray.length;i++){if(tokenArray[i].label!='TOC_HEADER'){continue;} |
587 | 588 | h++;markers.push({index:h,start:tokenArray[i].tokenStart,end:tokenArray[i].offset,anchor:'before',afterWrap:function(node){var marker=$(node).data('marker');$(node).addClass('wikiEditor-toc-header').addClass('wikiEditor-toc-section-'+marker.index).data('section',marker.index);},onSkip:function(node){var marker=$(node).data('marker');$(node).removeClass('wikiEditor-toc-section-'+$(node).data('section')).addClass('wikiEditor-toc-section-'+marker.index).data('section',marker.index);},getAnchor:function(ca1,ca2){return $(ca1.previousSibling).is('div.wikiEditor-toc-header')?ca1.previousSibling:null;}});outline.push({'text':tokenArray[i].match[2],'level':tokenArray[i].match[1].length,'index':h});} |
588 | 589 | $.wikiEditor.modules.toc.fn.build(context);$.wikiEditor.modules.toc.fn.update(context);}},exp:[{'regex':/^(={1,6})([^\r\n]+?)\1\s*$/m,'label':'TOC_HEADER','markAfter':true}],fn:{create:function(context,config){if('$toc'in context.modules.toc){return;} |
589 | 590 | $.wikiEditor.modules.toc.cfg.rtl=config.rtl;var height=context.$ui.find('.wikiEditor-ui-left').height();context.modules.toc.$toc=$('<div />').addClass('wikiEditor-ui-toc').data('context',context).data('positionMode','regular').data('collapsed',false);context.$ui.find('.wikiEditor-ui-right').append(context.modules.toc.$toc);context.modules.toc.$toc.height(context.$ui.find('.wikiEditor-ui-left').height());$.wikiEditor.modules.toc.fn.redraw(context,$.wikiEditor.modules.toc.cfg.defaultWidth);},redraw:function(context,fixedWidth){var fixedWidth=parseFloat(fixedWidth);if(context.modules.toc.$toc.data('positionMode')=='regular'){context.$ui.find('.wikiEditor-ui-right').css('width',fixedWidth+'px');context.$ui.find('.wikiEditor-ui-left').css('marginRight',(-1*fixedWidth)+'px').children().css('marginRight',fixedWidth+'px');}else if(context.modules.toc.$toc.data('positionMode')=='goofy'){context.$ui.find('.wikiEditor-ui-left').css('width',fixedWidth);context.$ui.find('.wikiEditor-ui-right').css($.wikiEditor.modules.toc.cfg.rtl?'right':'left',fixedWidth);context.$wikitext.css('height',context.$ui.find('.wikiEditor-ui-right').height());}},switchLayout:function(context){var width,height=context.$ui.find('.wikiEditor-ui-right').height();if(context.modules.toc.$toc.data('positionMode')=='regular'&&!context.modules.toc.$toc.data('collapsed')){context.modules.toc.$toc.data('positionMode','goofy');context.modules.toc.$toc.data('positionModeChangeAt',context.$ui.find('.wikiEditor-ui-right').width());width=$.wikiEditor.modules.toc.cfg.textMinimumWidth;context.$ui.find('.wikiEditor-ui-left').css({'marginRight':'','position':'absolute','float':'none','left':$.wikiEditor.modules.toc.cfg.rtl?'auto':0,'right':$.wikiEditor.modules.toc.cfg.rtl?0:'auto'}).children().css('marginRight','');context.$ui.find('.wikiEditor-ui-right').css({'width':'auto','position':'absolute','float':'none','right':$.wikiEditor.modules.toc.cfg.rtl?'auto':0,'left':$.wikiEditor.modules.toc.cfg.rtl?0:'auto'});context.$wikitext.css('position','relative');}else if(context.modules.toc.$toc.data('positionMode')=='goofy'){context.modules.toc.$toc.data('positionMode','regular');width=context.$wikitext.width()-context.$ui.find('.wikiEditor-ui-left').width();if(width>context.modules.toc.$toc.data('positionModeChangeAt')){width=context.modules.toc.$toc.data('positionModeChangeAt');} |