MediaWiki:Common.js: Διαφορά μεταξύ των αναθεωρήσεων

Από Trace Project
Χωρίς σύνοψη επεξεργασίας
Χωρίς σύνοψη επεξεργασίας
Γραμμή 1: Γραμμή 1:


$(document).ready(function () {
$(document).ready(function () {
screenCheck();


$('.scroll-control .one').click(function () {
$('.scroll-control .one').click(function () {
Γραμμή 14: Γραμμή 14:
});
});


$(window).on('resize', function () {
screenCheck();
});
 
function applyScroll() {
function applyScroll() {
$.scrollify({
$.scrollify({
Γραμμή 34: Γραμμή 31:
}
}


function screenCheck() {
var deviceAgent = navigator.userAgent.toLowerCase();
var agentID = deviceAgent.match(/(iphone|ipod|ipad)/);
if (agentID || $(window).width() <= 1024) {
// its mobile screen
$.scrollify.destroy();
$('section').removeClass('scroll').removeAttr('style');
$.scrollify.disable();
} else {
// its desktop
$('section').addClass('scroll');
applyScroll();
$.scrollify.enable();
}
}
}

Αναθεώρηση της 23:53, 15 Φεβρουαρίου 2023


$(document).ready(function () {
	

				$('.scroll-control .one').click(function () {
					$.scrollify.move('#s-one');
				});
				$('.scroll-control .two').click(function () {
					$.scrollify.move('#s-two');
				});
				$('.scroll-control .three').click(function () {
					$.scrollify.move('#s-three');
				});
			});

			
			function applyScroll() {
				$.scrollify({
					section: '.scroll',
					sectionName: 'section-name',
					//standardScrollElements: 'section',
					easing: 'easeOutExpo',
					scrollSpeed: 1100,
					offset: 0,
					scrollbars: true,
					setHeights: false,
					overflowScroll: true,
					updateHash: false,
					touchScroll: true,
				});
			}

			}