[MediaWiki-commits] [Gerrit] wikidata...gui[master]: Moved CSS to LESS, added grunt support

2017-10-16 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/383774 )

Change subject: Moved CSS to LESS, added grunt support
..


Moved CSS to LESS, added grunt support

The grunt build generates style.css from style.less. Additionally, for
local development, a section is added to index.html which compiles the
stylesheet in the client, so that after just `npm install` it is
possible to open index.html in the browser and have it working. In the
build, this section is discarded by htmlmin.

Change-Id: Ie4720ac9f212ced0d36ce54bc1a6c7ab294daada
---
M .gitignore
M Gruntfile.js
M index.html
M package.json
R style.less
5 files changed, 17 insertions(+), 2 deletions(-)

Approvals:
  Jonas Kress (WMDE): Looks good to me, approved
  Yurik: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/.gitignore b/.gitignore
index 709d14c..2b8fdc8 100644
--- a/.gitignore
+++ b/.gitignore
@@ -7,3 +7,4 @@
 package-lock.json
 *.iml
 npm-debug.log
+style.css
diff --git a/Gruntfile.js b/Gruntfile.js
index 06983bc..d6b1374 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -28,9 +28,16 @@
'wikibase/tests/*.html'
]
},
+   less: {
+   all: {
+   files: {
+   'style.css': 'style.less'
+   }
+   }
+   },
stylelint: {
all: [
-   'style.css'
+   'style.less'
]
},
banana: {
@@ -227,7 +234,7 @@
'clean', 'create_build'
] );
grunt.registerTask( 'create_build', [
-   'auto_install', 'test', 'copy', 'useminPrepare', 'concat', 
'cssmin', 'uglify', 'filerev', 'usemin', 'htmlmin', 'merge-i18n'
+   'auto_install', 'test', 'less', 'copy', 'useminPrepare', 
'concat', 'cssmin', 'uglify', 'filerev', 'usemin', 'htmlmin', 'merge-i18n'
] );
grunt.registerTask( 'deploy', [
'clean', 'shell:updateRepo', 'shell:cloneDeploy', 
'clean:deploy', 'create_build', 'shell:commitDeploy', 'configDeploy', 
'shell:review'
diff --git a/index.html b/index.html
index bfe3aad..abca5e7 100644
--- a/index.html
+++ b/index.html
@@ -31,6 +31,12 @@


 
+   
+   
+   
+   less.watch()
+   
+



diff --git a/package.json b/package.json
index a196ec4..e2f2613 100644
--- a/package.json
+++ b/package.json
@@ -55,6 +55,7 @@
 "grunt-contrib-cssmin": "^2.2.0",
 "grunt-contrib-htmlmin": "^2.4.0",
 "grunt-contrib-jshint": "^1.1.0",
+"grunt-contrib-less": "^1.4.1",
 "grunt-contrib-qunit": "^2.0.0",
 "grunt-contrib-uglify": "^3.0.1",
 "grunt-filerev": "^2.3.1",
diff --git a/style.css b/style.less
similarity index 100%
rename from style.css
rename to style.less

-- 
To view, visit https://gerrit.wikimedia.org/r/383774
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie4720ac9f212ced0d36ce54bc1a6c7ab294daada
Gerrit-PatchSet: 5
Gerrit-Project: wikidata/query/gui
Gerrit-Branch: master
Gerrit-Owner: Yurik 
Gerrit-Reviewer: Jonas Kress (WMDE) 
Gerrit-Reviewer: Lucas Werkmeister (WMDE) 
Gerrit-Reviewer: Smalyshev 
Gerrit-Reviewer: Yurik 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] wikidata...gui[master]: Moved CSS to LESS, added grunt support

2017-10-11 Thread Yurik (Code Review)
Yurik has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/383774 )

Change subject: Moved CSS to LESS, added grunt support
..

Moved CSS to LESS, added grunt support

Change-Id: Ie4720ac9f212ced0d36ce54bc1a6c7ab294daada
---
M Gruntfile.js
M package.json
R style.less
3 files changed, 10 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikidata/query/gui 
refs/changes/74/383774/1

diff --git a/Gruntfile.js b/Gruntfile.js
index 06983bc..d6b1374 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -28,9 +28,16 @@
'wikibase/tests/*.html'
]
},
+   less: {
+   all: {
+   files: {
+   'style.css': 'style.less'
+   }
+   }
+   },
stylelint: {
all: [
-   'style.css'
+   'style.less'
]
},
banana: {
@@ -227,7 +234,7 @@
'clean', 'create_build'
] );
grunt.registerTask( 'create_build', [
-   'auto_install', 'test', 'copy', 'useminPrepare', 'concat', 
'cssmin', 'uglify', 'filerev', 'usemin', 'htmlmin', 'merge-i18n'
+   'auto_install', 'test', 'less', 'copy', 'useminPrepare', 
'concat', 'cssmin', 'uglify', 'filerev', 'usemin', 'htmlmin', 'merge-i18n'
] );
grunt.registerTask( 'deploy', [
'clean', 'shell:updateRepo', 'shell:cloneDeploy', 
'clean:deploy', 'create_build', 'shell:commitDeploy', 'configDeploy', 
'shell:review'
diff --git a/package.json b/package.json
index a196ec4..e2f2613 100644
--- a/package.json
+++ b/package.json
@@ -55,6 +55,7 @@
 "grunt-contrib-cssmin": "^2.2.0",
 "grunt-contrib-htmlmin": "^2.4.0",
 "grunt-contrib-jshint": "^1.1.0",
+"grunt-contrib-less": "^1.4.1",
 "grunt-contrib-qunit": "^2.0.0",
 "grunt-contrib-uglify": "^3.0.1",
 "grunt-filerev": "^2.3.1",
diff --git a/style.css b/style.less
similarity index 100%
rename from style.css
rename to style.less

-- 
To view, visit https://gerrit.wikimedia.org/r/383774
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie4720ac9f212ced0d36ce54bc1a6c7ab294daada
Gerrit-PatchSet: 1
Gerrit-Project: wikidata/query/gui
Gerrit-Branch: master
Gerrit-Owner: Yurik 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits