(function($){
	$.fn.shider = function(settings){
		return this.each(function(){
			settings = $.extend({
				animation: 'quick',
				speed: 'slow',
				showText: 'Pokaż więcej',
				hideText: 'Schowaj',
				buttonClass: 'more'
			}, settings);
			$(this).css({
				display: 'none',
				overflow: 'hidden'
			});
			$(this).before('<a href="javascript:void(0);" class="' + settings.buttonClass + '">' + settings.showText + '</a>');
			$(this).prev().toggle(
				function(){
					$(this).html(settings.hideText);
					switch (settings.animation){
						case 'quick':
							$(this).next().show();
						break;
						case 'show':
							$(this).next().show(settings.speed);
						break;
						case 'fade':
							$(this).next().fadeIn(settings.speed);
						break;
						case 'slide':
							$(this).next().slideDown(settings.speed);
						break;
					}
				},
				function(){
					$(this).html(settings.showText);
					switch (settings.animation){
						case 'quick':
							$(this).next().hide();
						break;
						case 'show':
							$(this).next().hide(settings.speed);
						break;
						case 'fade':
							$(this).next().fadeOut(settings.speed);
						break;
						case 'slide':
							$(this).next().slideUp(settings.speed);
						break;
					}
				}
			);
		});
	};
})(jQuery);