mirror of
https://github.com/vichan-devel/vichan.git
synced 2024-11-23 23:20:57 +01:00
document mobile-style.js ( vichan-devel/Tinyboard#26 )
This commit is contained in:
parent
9039d9c4d9
commit
875a2df521
@ -1,3 +1,16 @@
|
|||||||
|
/*
|
||||||
|
* mobile-style.js - adds some responsiveness to Tinyboard
|
||||||
|
* https://github.com/vichan-devel/Tinyboard/blob/master/js/mobile-style.js
|
||||||
|
*
|
||||||
|
* Released under the MIT license
|
||||||
|
* Copyright (c) 2014 Marcin Łabanowski <marcin@6irc.net>
|
||||||
|
*
|
||||||
|
* Usage:
|
||||||
|
* $config['api']['enabled'] = true;
|
||||||
|
* $config['additional_javascript'][] = 'js/jquery.min.js';
|
||||||
|
* $config['additional_javascript'][] = 'js/mobile-style.js';
|
||||||
|
*/
|
||||||
|
|
||||||
if(navigator.userAgent.match(/iPhone|iPod|iPad|Android|Opera Mini|Blackberry|PlayBook|Windows Phone|Tablet PC|Windows CE|IEMobile/i)) {
|
if(navigator.userAgent.match(/iPhone|iPod|iPad|Android|Opera Mini|Blackberry|PlayBook|Windows Phone|Tablet PC|Windows CE|IEMobile/i)) {
|
||||||
$('html').addClass("mobile-style");
|
$('html').addClass("mobile-style");
|
||||||
device_type = "mobile";
|
device_type = "mobile";
|
||||||
|
Loading…
Reference in New Issue
Block a user