مدیاویکی:Gadget-sidebarToggle.js: تفاوت میان نسخه‌ها

بدون خلاصۀ ویرایش
بدون خلاصۀ ویرایش
 
(۲ نسخهٔ میانیِ ایجادشده توسط همین کاربر نشان داده نشد)
خط ۱: خط ۱:
(function( $, undefined ) {
(function( $, undefined ) {
   
   
خط ۸۷: خط ۸۶:
  * @param duration {mixed} Animation duration passed to jQuery.
  * @param duration {mixed} Animation duration passed to jQuery.
  */
  */
/*
function collapse( duration ) {
function collapse( duration ) {
   
   
خط ۱۲۲: خط ۱۲۲:
   
   
}
}
 
/**
/**
  * Expands the sidebar.
  * Expands the sidebar.
  * @param duration {mixed} Animation duration passed to jQuery.
  * @param duration {mixed} Animation duration passed to jQuery.
*/
 
function expand( duration ) {
function expand( duration ) {
   
   
خط ۱۶۰: خط ۱۶۰:
   
   
}
}
 
*/
function totop() {
function totop() {
$('html, body').animate({ scrollTop: 0 }, 500);
$('html, body').animate({ scrollTop: 0 }, 500);
خط ۱۸۹: خط ۱۸۹:
   
   
// Show the toggle tab.
// Show the toggle tab.
$("<a class='sidebarbottons' id='collsidebar'></a>")
//$("<a class='sidebarbottons' id='collsidebar'></a>")
.prop( "title", "تغییر وضعیت فهرست سمت راست" )
// .prop( "title", "تغییر وضعیت فهرست سمت راست" )
.click( toggle )
// .click( toggle )
.insertAfter("#mw-panel");
// .insertAfter("#mw-panel");
$("<a class='sidebarbottons' id='totop'></a>")
$("<a class='sidebarbottons' id='totop'></a>")
خط ۲۲۹: خط ۲۲۹:
// Load translations and saved state.
// Load translations and saved state.
dir = document.documentElement.dir;
dir = document.documentElement.dir;
$.extend( msg, translations[document.documentElement.lang] );
//$.extend( msg, translations[document.documentElement.lang] );
loadState();
loadState();