Skip to content

Commit

Permalink
realfavicongenerator added
Browse files Browse the repository at this point in the history
  • Loading branch information
Simounet committed Jan 8, 2017
1 parent 0515cb7 commit 19e6bb6
Show file tree
Hide file tree
Showing 19 changed files with 217 additions and 1 deletion.
1 change: 1 addition & 0 deletions faviconData.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"result":{"status":"success"},"favicon":{"package_url":"https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/favicons.zip","files_urls":["https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/android-chrome-192x192.png","https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/android-chrome-512x512.png","https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/apple-touch-icon.png","https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/browserconfig.xml","https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/favicon-16x16.png","https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/favicon-32x32.png","https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/favicon.ico","https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/manifest.json","https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/mstile-144x144.png","https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/mstile-150x150.png","https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/mstile-310x150.png","https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/mstile-310x310.png","https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/mstile-70x70.png","https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/package_files/safari-pinned-tab.svg"],"html_code":"<link rel=\"apple-touch-icon\" sizes=\"180x180\" href=\"/apple-touch-icon.png\">\n<link rel=\"icon\" type=\"image/png\" href=\"/favicon-32x32.png\" sizes=\"32x32\">\n<link rel=\"icon\" type=\"image/png\" href=\"/favicon-16x16.png\" sizes=\"16x16\">\n<link rel=\"manifest\" href=\"/manifest.json\">\n<link rel=\"mask-icon\" href=\"/safari-pinned-tab.svg\" color=\"#5bbad5\">\n<meta name=\"msapplication-TileColor\" content=\"#da532c\">\n<meta name=\"msapplication-TileImage\" content=\"/mstile-144x144.png\">\n<meta name=\"theme-color\" content=\"#424242\">","compression":"false","overlapping_markups":["link[rel=\"apple-touch-icon\"]","link[rel=\"shortcut\"]","link[rel=\"shortcut icon\"]","link[rel=\"icon\",sizes=\"16x16\"]","link[rel=\"icon\",sizes=\"32x32\"]","meta[name=\"msapplication-TileColor\"]","meta[name=\"msapplication-TileImage\"]","link[rel=\"manifest\"]","meta[name=\"theme-color\"]","link[rel=\"mask-icon\"]"]},"files_location":{"type":"path","path":"/"},"preview_picture_url":"https://realfavicongenerator.net/files/a1d2520189de5f90c820708b801cc936f0dfcb6f/favicon_preview.png","version":"0.13"}
52 changes: 52 additions & 0 deletions faviconDescription.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
{
"masterPicture": "images/favicon.svg",
"iconsPath": "/",
"design": {
"ios": {
"pictureAspect": "noChange",
"assets": {
"ios6AndPriorIcons": false,
"ios7AndLaterIcons": false,
"precomposedIcons": false,
"declareOnlyDefaultIcon": true
}
},
"desktopBrowser": {},
"windows": {
"pictureAspect": "noChange",
"backgroundColor": "#da532c",
"onConflict": "override",
"assets": {
"windows80Ie10Tile": false,
"windows10Ie11EdgeTiles": {
"small": false,
"medium": true,
"big": false,
"rectangle": false
}
}
},
"androidChrome": {
"pictureAspect": "noChange",
"themeColor": "#ffffff",
"manifest": {
"display": "standalone",
"orientation": "notSet",
"onConflict": "override",
"declared": true
},
"assets": {
"legacyIcon": false,
"lowResolutionIcons": false
}
},
"safariPinnedTab": {
"pictureAspect": "silhouette",
"themeColor": "#5bbad5"
}
},
"settings": {
"scalingAlgorithm": "Mitchell",
"errorOnImageTooSmall": false
}
}
92 changes: 92 additions & 0 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ const sass = require('gulp-sass');
const sourcemaps = require('gulp-sourcemaps');
const autoprefixer = require('gulp-autoprefixer');

const realFavicon = require('gulp-real-favicon');
const fs = require('fs');
const FAVICON_DATA_FILE = 'faviconData.json';
const masterFavicon = 'images/favicon.svg';
const faviconsPath = 'images/favicons/';

gulp.task('css', () => {
return gulp.src('./sass/**/*.scss')
.pipe(sourcemaps.init())
Expand All @@ -20,3 +26,89 @@ gulp.task('css', () => {
gulp.task('css:watch', () => {
gulp.watch('./sass/**/*.scss', ['sass']);
});

// Generate the icons. This task takes a few seconds to complete.
// You should run it at least once to create the icons. Then,
// you should run it whenever RealFaviconGenerator updates its
// package (see the check-for-favicon-update task below).
gulp.task('favicon-generate', function (done) {
realFavicon.generateFavicon({
masterPicture: masterFavicon,
dest: faviconsPath,
iconsPath: '/',
design: {
ios: {
pictureAspect: 'noChange',
assets: {
ios6AndPriorIcons: false,
ios7AndLaterIcons: false,
precomposedIcons: false,
declareOnlyDefaultIcon: true
}
},
desktopBrowser: {},
windows: {
pictureAspect: 'noChange',
backgroundColor: '#da532c',
onConflict: 'override',
assets: {
windows80Ie10Tile: false,
windows10Ie11EdgeTiles: {
small: false,
medium: true,
big: false,
rectangle: false
}
}
},
androidChrome: {
pictureAspect: 'noChange',
themeColor: '#424242',
manifest: {
display: 'standalone',
orientation: 'notSet',
onConflict: 'override',
declared: true
},
assets: {
legacyIcon: false,
lowResolutionIcons: false
}
},
safariPinnedTab: {
pictureAspect: 'blackAndWhite',
threshold: 62.5,
themeColor: '#5bbad5'
}
},
settings: {
scalingAlgorithm: 'Mitchell',
errorOnImageTooSmall: false
},
markupFile: FAVICON_DATA_FILE
}, function () {
done();
});
});

// Inject the favicon markups in your HTML pages. You should run
// this task whenever you modify a page. You can keep this task
// as is or refactor your existing HTML pipeline.
gulp.task('favicon-inject', function () {
return gulp.src([ 'index.html' ])
.pipe(realFavicon.injectFaviconMarkups(JSON.parse(fs.readFileSync(FAVICON_DATA_FILE)).favicon.html_code))
.pipe(gulp.dest('.'));
});

// Check for updates on RealFaviconGenerator (think: Apple has just
// released a new Touch icon along with the latest version of iOS).
// Run this task from time to time. Ideally, make it part of your
// continuous integration system.
gulp.task('favicon-update', function (done) {
var currentVersion = JSON.parse(fs.readFileSync(FAVICON_DATA_FILE)).version;
realFavicon.checkForUpdates(currentVersion, function (err) {
if (err) {
throw err;
}
});
});
Binary file added images/favicons/android-chrome-192x192.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/favicons/android-chrome-512x512.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/favicons/apple-touch-icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 12 additions & 0 deletions images/favicons/browserconfig.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<browserconfig>
<msapplication>
<tile>
<square70x70logo src="/mstile-70x70.png"/>
<square150x150logo src="/mstile-150x150.png"/>
<square310x310logo src="/mstile-310x310.png"/>
<wide310x150logo src="/mstile-310x150.png"/>
<TileColor>#da532c</TileColor>
</tile>
</msapplication>
</browserconfig>
Binary file added images/favicons/favicon-16x16.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/favicons/favicon-32x32.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/favicons/favicon.ico
Binary file not shown.
17 changes: 17 additions & 0 deletions images/favicons/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"name": "",
"icons": [
{
"src": "\/android-chrome-192x192.png",
"sizes": "192x192",
"type": "image\/png"
},
{
"src": "\/android-chrome-512x512.png",
"sizes": "512x512",
"type": "image\/png"
}
],
"theme_color": "#424242",
"display": "standalone"
}
Binary file added images/favicons/mstile-144x144.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/favicons/mstile-150x150.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/favicons/mstile-310x150.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/favicons/mstile-310x310.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/favicons/mstile-70x70.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
34 changes: 34 additions & 0 deletions images/favicons/safari-pinned-tab.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 8 additions & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,20 @@
<title>{$delimiter=' · '}{if="isset($currentFeed)"}{$currentFeed->getName()}{$delimiter}{/if}{if="isset($currentFolder)"}{$currentFolder->getName()}{$delimiter}{/if}LeedVibes</title>
<link rel="stylesheet" href="css/style.css" media="all">
<meta name="viewport" content="width=device-width">
<link rel="icon" type="image/png" href="images/favicon.png" />
{function="Plugin::callLink()"}
{function="Plugin::callCss()"}
<script src="js/modernizr.custom.js"></script>
<!--[if lte IE 8]>
<script src="js/respond.js"></script>
<![endif]-->
<link rel="apple-touch-icon" sizes="180x180" href="images/favicons/apple-touch-icon.png">
<link rel="icon" type="image/png" href="images/favicons/favicon-32x32.png" sizes="32x32">
<link rel="icon" type="image/png" href="images/favicons/favicon-16x16.png" sizes="16x16">
<link rel="manifest" href="images/favicons/manifest.json">
<link rel="mask-icon" href="images/favicons/safari-pinned-tab.svg" color="#5bbad5">
<meta name="msapplication-TileColor" content="#da532c">
<meta name="msapplication-TileImage" content="images/favicons/mstile-144x144.png">
<meta name="theme-color" content="#424242">
<script src="js/jquery.min.js"></script>
<script src="js/script.js"></script>
{function="Plugin::callJs()"}
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
"eslint-plugin-standard": "^2.0.1",
"gulp": "^3.9.1",
"gulp-autoprefixer": "^3.1.1",
"gulp-real-favicon": "^0.2.2",
"gulp-sass": "^3.0.0",
"gulp-sourcemaps": "^1.9.1",
"stylelint": "^7.7.0"
Expand Down

0 comments on commit 19e6bb6

Please sign in to comment.