Comparing version 0.1.9 to 0.1.10
@@ -0,0 +0,0 @@ var project = require('../utils/project'); |
@@ -0,0 +0,0 @@ var fs = require('fs'); |
@@ -98,3 +98,5 @@ var fs = require('fs'); | ||
var index = fs.readFileSync("."+folder+"/index.html", "utf8") | ||
var config = fs.readFileSync("./config.xml", "utf8") | ||
var changeIndex = false; | ||
var changeConfig = false; | ||
if(css && index && index.indexOf('mobileui/style.css') < 0){ | ||
@@ -117,2 +119,11 @@ changeIndex=true | ||
} | ||
if(config && config.indexOf('DisallowOverscroll') < 0){ | ||
changeConfig=true | ||
config = config.replace('<content src="index.html" />','<content src="index.html" />\n <preference name="DisallowOverscroll" value="true" />') | ||
} | ||
if(changeConfig) { | ||
fs.writeFileSync("./config.xml",config) | ||
var msg = "> Config.xml updated to use mobileui."; | ||
console.log(msg.grey) | ||
} | ||
if(comp.files && comp.files.length){ | ||
@@ -119,0 +130,0 @@ var totalFiles = comp.files.length; |
@@ -0,0 +0,0 @@ var fs = require('fs'); |
@@ -0,0 +0,0 @@ var fs = require('fs'); |
{ | ||
"name": "mobileui", | ||
"version": "0.1.9", | ||
"version": "0.1.10", | ||
"description": "MobileUI is a simple and easy NPM package to install UI Components for web mobile apps using HTML, CSS and JavaScript.", | ||
@@ -5,0 +5,0 @@ "main": "./bin/mobileui", |
Sorry, the diff of this file is not supported yet
24790
501