Skip to content

charmpitz/sudoku-plugin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JQuery Sudoku plugin

Customize and create sudoku layouts for playing or presentations.

  • Responsive layout
  • Cross-browser support (tested in Chrome, Firefox, Safari, Opera, IE9)
  • 5 default theme colors

Tehnical support

These are some default values. For more information try understanding the code itself.

var defaults = {
	editable 			: true,
	touch 				: true,
	touchKeyboard 		: true,
	fullscreenMode 		: true,
	showOptions			: true,
	fullscreenEnterText	: 'Enter Fullscreen',
	fullscreenExitText	: 'Exit Fullscreen',
	resetText 			: 'Reset',
	pauseText			: 'Pause',
	unpauseText			: 'Unpause',
	onComplete			: function(){},
	onChange			: function(){},
	onFill				: function(){}, 	// When all the editable cells are filled
	onFullscreenEnter	: function(){},
	onFullscreenExit	: function(){},
	onPause				: function(){},
	onUnpause			: function(){},
	onStart				: function(){}
};

###Available Methods: ---
  • readonly

Makes the instance readonly

$(elem).sudoku('readonly');

  • editable

Enables editing capabilities

$(elem).sudoku('editable', true);

  • fullscreen

Enable/Disable fullscreen mode on certain instance

$(elem).sudoku('fullscreen', true);

  • touch

Enable/Disable touch capabilities for the instance

$(elem).sudoku('touch', true);

  • keyboard

Show/Hide the side-keyboard (must be enabled for touch)

$(elem).sudoku('keyboard', true);

  • reset

Resets the cells

$(elem).sudoku('reset');

  • hideOptions

Hides the options panel

$(elem).sudoku('hideOptions');

  • showOptions

Shows the options panel

$(elem).sudoku('showOptions');

  • pauseGame

Pauses the game

$(elem).sudoku('pauseGame');

  • unpauseGame

Unpauses the game

$(elem).sudoku('unpauseGame');

Live Demos

http://sudoku.andreipitz.eu

http://www.sudokuonline.nl/

Version

1.0

Third parties

JQuery Sudoku Plugin uses a number of open source projects to work (some of them are optional):

License

MIT