43 lines
571 B
JavaScript
43 lines
571 B
JavaScript
|
|
module.exports =
|
|
{
|
|
getPageYOffset: function ()
|
|
{
|
|
return window.pageYOffset;
|
|
},
|
|
|
|
getPageXOffset: function ()
|
|
{
|
|
return window.pageXOffset;
|
|
},
|
|
|
|
getInnerHeight: function ()
|
|
{
|
|
return window.innerHeight;
|
|
},
|
|
|
|
getInnerWidth: function ()
|
|
{
|
|
return window.innerWidth;
|
|
},
|
|
|
|
createRadio: function (uid, doc)
|
|
{
|
|
var radio = doc.createElement ('input');
|
|
radio.type = 'radio';
|
|
radio.name = uid;
|
|
return radio;
|
|
},
|
|
|
|
setInputTypeNumber: function (input)
|
|
{
|
|
input.type = 'number';
|
|
}
|
|
};
|
|
|
|
if (!console.warn)
|
|
{
|
|
console.log (1);
|
|
console.warn = console.log;
|
|
}
|