Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
36ee2b8298 | ||
|
|
7a30b52ad6 | ||
|
|
8a89efc74a | ||
|
|
2edc584359 | ||
|
|
dfd0df0a59 | ||
|
|
3e98e714c6 | ||
|
|
2f88823b00 |
@@ -0,0 +1,3 @@
|
|||||||
|
2015-10-20 v0.3.3
|
||||||
|
|
||||||
|
ECARROLL- Updated to remove Grunt, and coffeescript stuff.
|
||||||
@@ -1,65 +0,0 @@
|
|||||||
fs = require("fs")
|
|
||||||
|
|
||||||
#global module:false
|
|
||||||
module.exports = (grunt) ->
|
|
||||||
|
|
||||||
# Project configuration.
|
|
||||||
grunt.initConfig
|
|
||||||
pkg: grunt.file.readJSON('package.json')
|
|
||||||
banner:
|
|
||||||
"/** <%= pkg.title || pkg.name %> - v<%= pkg.version %> - <%= grunt.template.today(\"yyyy/mm/dd\") %>\n"+
|
|
||||||
" * <%= pkg.homepage %>\n" +
|
|
||||||
" * Copyright (c) <%= grunt.template.today(\"yyyy\") %> <%= pkg.author.name %> - MIT\n"+
|
|
||||||
" */\n"
|
|
||||||
|
|
||||||
coffee:
|
|
||||||
options:
|
|
||||||
bare: true
|
|
||||||
compile:
|
|
||||||
expand: true,
|
|
||||||
flatten: false,
|
|
||||||
cwd: 'src',
|
|
||||||
src: ['**/*.coffee'],
|
|
||||||
dest: 'dist/',
|
|
||||||
ext: '.js'
|
|
||||||
|
|
||||||
wrap:
|
|
||||||
dist:
|
|
||||||
src: 'dist/<%= pkg.name %>.js'
|
|
||||||
dest: '.'
|
|
||||||
wrapper: [
|
|
||||||
"<%= banner %>(function(window,document,$,undefined) {\n"
|
|
||||||
"\n}(window,document,jQuery));"
|
|
||||||
]
|
|
||||||
|
|
||||||
concat:
|
|
||||||
combined:
|
|
||||||
src: ['dist/<%= pkg.name %>.js', 'dist/styles/bootstrap/<%= pkg.name %>-bootstrap.js']
|
|
||||||
dest: 'dist/<%= pkg.name %>-combined.js'
|
|
||||||
|
|
||||||
uglify:
|
|
||||||
options:
|
|
||||||
stripBanners: true
|
|
||||||
banner: '<%= banner %>'
|
|
||||||
|
|
||||||
dist:
|
|
||||||
src: "dist/<%= pkg.name %>.js"
|
|
||||||
dest: "dist/<%= pkg.name %>.min.js"
|
|
||||||
|
|
||||||
combined:
|
|
||||||
src: "dist/<%= pkg.name %>-combined.js"
|
|
||||||
dest: "dist/<%= pkg.name %>-combined.min.js"
|
|
||||||
|
|
||||||
watch:
|
|
||||||
scripts:
|
|
||||||
files: 'src/**/*.coffee'
|
|
||||||
tasks: 'default'
|
|
||||||
|
|
||||||
grunt.loadNpmTasks "grunt-contrib-concat"
|
|
||||||
grunt.loadNpmTasks "grunt-contrib-watch"
|
|
||||||
grunt.loadNpmTasks "grunt-contrib-uglify"
|
|
||||||
grunt.loadNpmTasks "grunt-contrib-coffee"
|
|
||||||
grunt.loadNpmTasks "grunt-wrap"
|
|
||||||
|
|
||||||
# Default task.
|
|
||||||
grunt.registerTask "default", "coffee wrap concat uglify".split(' ')
|
|
||||||
@@ -0,0 +1,66 @@
|
|||||||
|
var fs = require("fs");
|
||||||
|
var process = require("process");
|
||||||
|
|
||||||
|
|
||||||
|
console.log("This file is now deprecated.. We no longer have a build system because we're not using coffee script.");
|
||||||
|
process.exit();
|
||||||
|
|
||||||
|
module.exports = function(grunt) {
|
||||||
|
grunt.initConfig({
|
||||||
|
pkg: grunt.file.readJSON('package.json'),
|
||||||
|
banner: "/** <%= pkg.title || pkg.name %> - v<%= pkg.version %> - <%= grunt.template.today(\"yyyy/mm/dd\") %>\n" + " * <%= pkg.homepage %>\n" + " * Copyright (c) <%= grunt.template.today(\"yyyy\") %> <%= pkg.author.name %> - MIT\n" + " */\n",
|
||||||
|
coffee: {
|
||||||
|
options: {
|
||||||
|
bare: true
|
||||||
|
},
|
||||||
|
compile: {
|
||||||
|
expand: true,
|
||||||
|
flatten: false,
|
||||||
|
cwd: 'src',
|
||||||
|
src: ['**/*.coffee'],
|
||||||
|
dest: 'dist/',
|
||||||
|
ext: '.js'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
wrap: {
|
||||||
|
dist: {
|
||||||
|
src: 'dist/<%= pkg.name %>.js',
|
||||||
|
dest: '.',
|
||||||
|
wrapper: ["<%= banner %>(function(window,document,$,undefined) {\n", "\n}(window,document,jQuery));"]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
concat: {
|
||||||
|
combined: {
|
||||||
|
src: ['dist/<%= pkg.name %>.js', 'dist/styles/bootstrap/<%= pkg.name %>-bootstrap.js'],
|
||||||
|
dest: 'dist/<%= pkg.name %>-combined.js'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
uglify: {
|
||||||
|
options: {
|
||||||
|
stripBanners: true,
|
||||||
|
banner: '<%= banner %>'
|
||||||
|
},
|
||||||
|
dist: {
|
||||||
|
src: "dist/<%= pkg.name %>.js",
|
||||||
|
dest: "dist/<%= pkg.name %>.min.js"
|
||||||
|
},
|
||||||
|
combined: {
|
||||||
|
src: "dist/<%= pkg.name %>-combined.js",
|
||||||
|
dest: "dist/<%= pkg.name %>-combined.min.js"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
watch: {
|
||||||
|
scripts: {
|
||||||
|
files: 'src/**/*.coffee',
|
||||||
|
tasks: 'default'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
grunt.loadNpmTasks("grunt-contrib-concat");
|
||||||
|
grunt.loadNpmTasks("grunt-contrib-watch");
|
||||||
|
grunt.loadNpmTasks("grunt-contrib-uglify");
|
||||||
|
grunt.loadNpmTasks("grunt-contrib-coffee");
|
||||||
|
grunt.loadNpmTasks("grunt-wrap");
|
||||||
|
return grunt.registerTask("default", "coffee wrap concat uglify".split(' '));
|
||||||
|
};
|
||||||
|
|
||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "notifyjs",
|
"name": "notifyjs",
|
||||||
"version": "0.3.1",
|
"version": "0.3.2",
|
||||||
"homepage": "http://notifyjs.com/",
|
"homepage": "http://notifyjs.com/",
|
||||||
"authors": [
|
"authors": [
|
||||||
"Jaime Pillora <dev@jpillora.com>"
|
"Jaime Pillora <dev@jpillora.com>"
|
||||||
|
|||||||
Vendored
+11
-8
@@ -1,4 +1,4 @@
|
|||||||
/** Notify.js - v0.3.1 - 2014/02/06
|
/** Notify.js - v0.3.1 - 2014/06/29
|
||||||
* http://notifyjs.com/
|
* http://notifyjs.com/
|
||||||
* Copyright (c) 2014 Jaime Pillora - MIT
|
* Copyright (c) 2014 Jaime Pillora - MIT
|
||||||
*/
|
*/
|
||||||
@@ -56,7 +56,7 @@ styles = {};
|
|||||||
coreStyle = {
|
coreStyle = {
|
||||||
name: 'core',
|
name: 'core',
|
||||||
html: "<div class=\"" + pluginClassName + "-wrapper\">\n <div class=\"" + pluginClassName + "-arrow\"></div>\n <div class=\"" + pluginClassName + "-container\"></div>\n</div>",
|
html: "<div class=\"" + pluginClassName + "-wrapper\">\n <div class=\"" + pluginClassName + "-arrow\"></div>\n <div class=\"" + pluginClassName + "-container\"></div>\n</div>",
|
||||||
css: "." + pluginClassName + "-corner {\n position: fixed;\n margin: 5px;\n z-index: 1050;\n}\n\n." + pluginClassName + "-corner ." + pluginClassName + "-wrapper,\n." + pluginClassName + "-corner ." + pluginClassName + "-container {\n position: relative;\n display: block;\n height: inherit;\n width: inherit;\n margin: 3px;\n}\n\n." + pluginClassName + "-wrapper {\n z-index: 1;\n position: absolute;\n display: inline-block;\n height: 0;\n width: 0;\n}\n\n." + pluginClassName + "-container {\n display: none;\n z-index: 1;\n position: absolute;\n cursor: pointer;\n}\n\n[data-notify-text],[data-notify-html] {\n position: relative;\n}\n\n." + pluginClassName + "-arrow {\n position: absolute;\n z-index: 2;\n width: 0;\n height: 0;\n}"
|
css: "." + pluginClassName + "-corner {\n position: fixed;\n margin: 5px;\n z-index: 1050;\n}\n\n." + pluginClassName + "-corner ." + pluginClassName + "-wrapper,\n." + pluginClassName + "-corner ." + pluginClassName + "-container {\n position: relative;\n display: block;\n height: inherit;\n width: inherit;\n margin: 3px;\n}\n\n." + pluginClassName + "-wrapper {\n z-index: 1;\n position: absolute;\n display: inline-block;\n height: 0;\n width: 0;\n}\n\n." + pluginClassName + "-container {\n display: none;\n z-index: 1;\n position: absolute;\n}\n\n." + pluginClassName + "-hidable {\n cursor: pointer;\n}\n\n[data-notify-text],[data-notify-html] {\n position: relative;\n}\n\n." + pluginClassName + "-arrow {\n position: absolute;\n z-index: 2;\n width: 0;\n height: 0;\n}"
|
||||||
};
|
};
|
||||||
|
|
||||||
stylePrefixes = {
|
stylePrefixes = {
|
||||||
@@ -249,6 +249,9 @@ Notification = (function() {
|
|||||||
this.options = inherit(pluginOptions, $.isPlainObject(options) ? options : {});
|
this.options = inherit(pluginOptions, $.isPlainObject(options) ? options : {});
|
||||||
this.loadHTML();
|
this.loadHTML();
|
||||||
this.wrapper = $(coreStyle.html);
|
this.wrapper = $(coreStyle.html);
|
||||||
|
if (this.options.clickToHide) {
|
||||||
|
this.wrapper.addClass("" + pluginClassName + "-hidable");
|
||||||
|
}
|
||||||
this.wrapper.data(pluginClassName, this);
|
this.wrapper.data(pluginClassName, this);
|
||||||
this.arrow = this.wrapper.find("." + pluginClassName + "-arrow");
|
this.arrow = this.wrapper.find("." + pluginClassName + "-arrow");
|
||||||
this.container = this.wrapper.find("." + pluginClassName + "-container");
|
this.container = this.wrapper.find("." + pluginClassName + "-container");
|
||||||
@@ -536,12 +539,12 @@ $.extend($[pluginName], {
|
|||||||
|
|
||||||
$(function() {
|
$(function() {
|
||||||
insertCSS(coreStyle.css).attr('id', 'core-notify');
|
insertCSS(coreStyle.css).attr('id', 'core-notify');
|
||||||
return $(document).on('click notify-hide', "." + pluginClassName + "-wrapper", function(e) {
|
$(document).on('click', "." + pluginClassName + "-hidable", function(e) {
|
||||||
var inst;
|
return $(this).trigger('notify-hide');
|
||||||
inst = $(this).data(pluginClassName);
|
});
|
||||||
if (inst && (inst.options.clickToHide || e.type === 'notify-hide')) {
|
return $(document).on('notify-hide', "." + pluginClassName + "-wrapper", function(e) {
|
||||||
return inst.show(false);
|
var _ref;
|
||||||
}
|
return (_ref = $(this).data(pluginClassName)) != null ? _ref.show(false) : void 0;
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Vendored
+2
-2
File diff suppressed because one or more lines are too long
Vendored
+10
-11
@@ -1,7 +1,3 @@
|
|||||||
/** Notify.js - v0.3.1 - 2014/02/06
|
|
||||||
* http://notifyjs.com/
|
|
||||||
* Copyright (c) 2014 Jaime Pillora - MIT
|
|
||||||
*/
|
|
||||||
(function(window,document,$,undefined) {
|
(function(window,document,$,undefined) {
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
@@ -56,7 +52,7 @@ styles = {};
|
|||||||
coreStyle = {
|
coreStyle = {
|
||||||
name: 'core',
|
name: 'core',
|
||||||
html: "<div class=\"" + pluginClassName + "-wrapper\">\n <div class=\"" + pluginClassName + "-arrow\"></div>\n <div class=\"" + pluginClassName + "-container\"></div>\n</div>",
|
html: "<div class=\"" + pluginClassName + "-wrapper\">\n <div class=\"" + pluginClassName + "-arrow\"></div>\n <div class=\"" + pluginClassName + "-container\"></div>\n</div>",
|
||||||
css: "." + pluginClassName + "-corner {\n position: fixed;\n margin: 5px;\n z-index: 1050;\n}\n\n." + pluginClassName + "-corner ." + pluginClassName + "-wrapper,\n." + pluginClassName + "-corner ." + pluginClassName + "-container {\n position: relative;\n display: block;\n height: inherit;\n width: inherit;\n margin: 3px;\n}\n\n." + pluginClassName + "-wrapper {\n z-index: 1;\n position: absolute;\n display: inline-block;\n height: 0;\n width: 0;\n}\n\n." + pluginClassName + "-container {\n display: none;\n z-index: 1;\n position: absolute;\n cursor: pointer;\n}\n\n[data-notify-text],[data-notify-html] {\n position: relative;\n}\n\n." + pluginClassName + "-arrow {\n position: absolute;\n z-index: 2;\n width: 0;\n height: 0;\n}"
|
css: "." + pluginClassName + "-corner {\n position: fixed;\n margin: 5px;\n z-index: 1050;\n}\n\n." + pluginClassName + "-corner ." + pluginClassName + "-wrapper,\n." + pluginClassName + "-corner ." + pluginClassName + "-container {\n position: relative;\n display: block;\n height: inherit;\n width: inherit;\n margin: 3px;\n}\n\n." + pluginClassName + "-wrapper {\n z-index: 1;\n position: absolute;\n display: inline-block;\n height: 0;\n width: 0;\n}\n\n." + pluginClassName + "-container {\n display: none;\n z-index: 1;\n position: absolute;\n}\n\n." + pluginClassName + "-hidable {\n cursor: pointer;\n}\n\n[data-notify-text],[data-notify-html] {\n position: relative;\n}\n\n." + pluginClassName + "-arrow {\n position: absolute;\n z-index: 2;\n width: 0;\n height: 0;\n}"
|
||||||
};
|
};
|
||||||
|
|
||||||
stylePrefixes = {
|
stylePrefixes = {
|
||||||
@@ -249,6 +245,9 @@ Notification = (function() {
|
|||||||
this.options = inherit(pluginOptions, $.isPlainObject(options) ? options : {});
|
this.options = inherit(pluginOptions, $.isPlainObject(options) ? options : {});
|
||||||
this.loadHTML();
|
this.loadHTML();
|
||||||
this.wrapper = $(coreStyle.html);
|
this.wrapper = $(coreStyle.html);
|
||||||
|
if (this.options.clickToHide) {
|
||||||
|
this.wrapper.addClass("" + pluginClassName + "-hidable");
|
||||||
|
}
|
||||||
this.wrapper.data(pluginClassName, this);
|
this.wrapper.data(pluginClassName, this);
|
||||||
this.arrow = this.wrapper.find("." + pluginClassName + "-arrow");
|
this.arrow = this.wrapper.find("." + pluginClassName + "-arrow");
|
||||||
this.container = this.wrapper.find("." + pluginClassName + "-container");
|
this.container = this.wrapper.find("." + pluginClassName + "-container");
|
||||||
@@ -536,12 +535,12 @@ $.extend($[pluginName], {
|
|||||||
|
|
||||||
$(function() {
|
$(function() {
|
||||||
insertCSS(coreStyle.css).attr('id', 'core-notify');
|
insertCSS(coreStyle.css).attr('id', 'core-notify');
|
||||||
return $(document).on('click notify-hide', "." + pluginClassName + "-wrapper", function(e) {
|
$(document).on('click', "." + pluginClassName + "-hidable", function(e) {
|
||||||
var inst;
|
return $(this).trigger('notify-hide');
|
||||||
inst = $(this).data(pluginClassName);
|
});
|
||||||
if (inst && (inst.options.clickToHide || e.type === 'notify-hide')) {
|
return $(document).on('notify-hide', "." + pluginClassName + "-wrapper", function(e) {
|
||||||
return inst.show(false);
|
var _ref;
|
||||||
}
|
return (_ref = $(this).data(pluginClassName)) != null ? _ref.show(false) : void 0;
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Vendored
+3
-3
File diff suppressed because one or more lines are too long
@@ -1,7 +1,8 @@
|
|||||||
{
|
{
|
||||||
"source": "~/.grunt-sources/web",
|
"source": "~/.grunt-sources/web",
|
||||||
"repo": "https://github.com/jpillora/grunt-source-web",
|
"repo": "https://github.com/jpillora/grunt-source-web.git",
|
||||||
"output": {
|
"output": {
|
||||||
"html": "../index.html"
|
"html": "../index.html"
|
||||||
}
|
},
|
||||||
|
"angular":true
|
||||||
}
|
}
|
||||||
+151
-58
@@ -569,49 +569,91 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* line 190 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
|
|
||||||
/* line 1 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/stylus/lib/functions/index.styl */
|
/* line 1 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/stylus/lib/functions/index.styl */
|
||||||
|
|
||||||
|
/* line 293 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/stylus/lib/functions/index.styl */
|
||||||
|
|
||||||
|
/* line 14 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/index.styl */
|
||||||
|
|
||||||
/* line 14 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/index.styl */
|
/* line 14 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/index.styl */
|
||||||
|
|
||||||
/* line 2 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/border.styl */
|
/* line 2 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/border.styl */
|
||||||
|
|
||||||
/* line 2 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/clearfix.styl */
|
/* line 12 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/border.styl */
|
||||||
|
|
||||||
|
/* line 3 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/clearfix.styl */
|
||||||
|
|
||||||
|
/* line 31 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/clearfix.styl */
|
||||||
|
|
||||||
/* line 2 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/color-image.styl */
|
/* line 2 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/color-image.styl */
|
||||||
|
|
||||||
|
/* line 6 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/color-image.styl */
|
||||||
|
|
||||||
/* line 6 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/flex.styl */
|
/* line 6 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/flex.styl */
|
||||||
|
|
||||||
/* line 154 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/gradients.styl */
|
/* line 197 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/flex.styl */
|
||||||
|
|
||||||
/* line 154 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/config.styl */
|
/* line 94 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/gradients.styl */
|
||||||
|
|
||||||
|
/* line 94 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/gradients.styl */
|
||||||
|
|
||||||
|
/* line 94 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/config.styl */
|
||||||
|
|
||||||
|
/* line 12 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/config.styl */
|
||||||
|
|
||||||
/* line 2 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/iconic.styl */
|
/* line 2 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/iconic.styl */
|
||||||
|
|
||||||
|
/* line 9 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/iconic.styl */
|
||||||
|
|
||||||
/* line 2 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/image.styl */
|
/* line 2 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/image.styl */
|
||||||
|
|
||||||
/* line 25 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/overflow.styl */
|
/* line 27 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/image.styl */
|
||||||
|
|
||||||
/* line 3 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/positions.styl */
|
/* line 27 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/overflow.styl */
|
||||||
|
|
||||||
/* line 3 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/reset.styl */
|
/* line 23 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/overflow.styl */
|
||||||
|
|
||||||
|
/* line 9 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/positions.styl */
|
||||||
|
|
||||||
|
/* line 73 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/positions.styl */
|
||||||
|
|
||||||
|
/* line 15 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/reset.styl */
|
||||||
|
|
||||||
|
/* line 79 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/reset.styl */
|
||||||
|
|
||||||
|
/* line 5 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/index.styl */
|
||||||
|
|
||||||
/* line 5 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/index.styl */
|
/* line 5 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/index.styl */
|
||||||
|
|
||||||
/* line 2 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/aliases.styl */
|
/* line 2 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/aliases.styl */
|
||||||
|
|
||||||
|
/* line 14 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/aliases.styl */
|
||||||
|
|
||||||
/* line 2 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/ellipsis.styl */
|
/* line 2 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/ellipsis.styl */
|
||||||
|
|
||||||
|
/* line 11 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/ellipsis.styl */
|
||||||
|
|
||||||
/* line 11 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/hide-text.styl */
|
/* line 11 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/hide-text.styl */
|
||||||
|
|
||||||
|
/* line 9 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/hide-text.styl */
|
||||||
|
|
||||||
/* line 9 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/replace-text.styl */
|
/* line 9 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/replace-text.styl */
|
||||||
|
|
||||||
/* line 557 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/vendor.styl */
|
/* line 10 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/text/replace-text.styl */
|
||||||
|
|
||||||
/* line 557 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/config.styl */
|
/* line undefined : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/vendor.styl */
|
||||||
|
|
||||||
|
/* line 576 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/vendor.styl */
|
||||||
|
|
||||||
|
/* line 576 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/config.styl */
|
||||||
|
|
||||||
|
/* line 12 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/config.styl */
|
||||||
|
|
||||||
/* line 12 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/size.styl */
|
/* line 12 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/size.styl */
|
||||||
|
|
||||||
/* line 29 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/vendor/base.css */
|
/* line 33 : /Users/jpillora/.grunt-sources/web/node_modules/grunt-contrib-stylus/node_modules/nib/lib/nib/size.styl */
|
||||||
/*
|
/*
|
||||||
* Skeleton V1.2
|
* Skeleton V1.2
|
||||||
* Copyright 2011, Dave Gamache
|
* Copyright 2011, Dave Gamache
|
||||||
@@ -878,7 +920,7 @@
|
|||||||
.half-bottom { margin-bottom: 10px !important; }
|
.half-bottom { margin-bottom: 10px !important; }
|
||||||
.add-bottom { margin-bottom: 20px !important; }
|
.add-bottom { margin-bottom: 20px !important; }
|
||||||
|
|
||||||
/* line 29 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/vendor/skeleton.css */
|
/* line 33 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/vendor/base.css */
|
||||||
/*
|
/*
|
||||||
* Skeleton V1.2
|
* Skeleton V1.2
|
||||||
* Copyright 2011, Dave Gamache
|
* Copyright 2011, Dave Gamache
|
||||||
@@ -1122,7 +1164,7 @@
|
|||||||
height: 0;
|
height: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 29 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/vendor/layout.css */
|
/* line 33 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/vendor/skeleton.css */
|
||||||
/*
|
/*
|
||||||
* Skeleton V1.2
|
* Skeleton V1.2
|
||||||
* Copyright 2011, Dave Gamache
|
* Copyright 2011, Dave Gamache
|
||||||
@@ -1182,78 +1224,84 @@
|
|||||||
font-style: normal; }
|
font-style: normal; }
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* line 29 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/vendor/prettify.css */
|
/* line 33 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/vendor/layout.css */
|
||||||
.pln{color:#000}@media screen{.str{color:#080}.kwd{color:#008}.com{color:#800}.typ{color:#606}.lit{color:#066}.pun,.opn,.clo{color:#660}.tag{color:#008}.atn{color:#606}.atv{color:#080}.dec,.var{color:#606}.fun{color:red}}@media print,projection{.str{color:#060}.kwd{color:#006;font-weight:bold}.com{color:#600;font-style:italic}.typ{color:#404;font-weight:bold}.lit{color:#044}.pun,.opn,.clo{color:#440}.tag{color:#006;font-weight:bold}.atn{color:#404}.atv{color:#060}}pre.prettyprint{padding:2px;border:1px solid #888}ol.linenums{margin-top:0;margin-bottom:0}li.L0,li.L1,li.L2,li.L3,li.L5,li.L6,li.L7,li.L8{list-style-type:none}li.L1,li.L3,li.L5,li.L7,li.L9{background:#eee}
|
.pln{color:#000}@media screen{.str{color:#080}.kwd{color:#008}.com{color:#800}.typ{color:#606}.lit{color:#066}.pun,.opn,.clo{color:#660}.tag{color:#008}.atn{color:#606}.atv{color:#080}.dec,.var{color:#606}.fun{color:red}}@media print,projection{.str{color:#060}.kwd{color:#006;font-weight:bold}.com{color:#600;font-style:italic}.typ{color:#404;font-weight:bold}.lit{color:#044}.pun,.opn,.clo{color:#440}.tag{color:#006;font-weight:bold}.atn{color:#404}.atv{color:#060}}pre.prettyprint{padding:2px;border:1px solid #888}ol.linenums{margin-top:0;margin-bottom:0}li.L0,li.L1,li.L2,li.L3,li.L5,li.L6,li.L7,li.L8{list-style-type:none}li.L1,li.L3,li.L5,li.L7,li.L9{background:#eee}
|
||||||
|
|
||||||
/* line 12 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 14 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
h3 {
|
h3 {
|
||||||
text-decoration: underline;
|
text-decoration: underline;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 14 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 16 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
b {
|
b {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 16 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 18 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
i {
|
i {
|
||||||
font-style: italic !important;
|
font-style: italic !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 18 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 21 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
|
input:focus,
|
||||||
|
button {
|
||||||
|
outline: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* line 23 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
input[type="radio"],
|
input[type="radio"],
|
||||||
label[for] {
|
label[for] {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 20 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 25 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.main {
|
.main {
|
||||||
position: relative;
|
position: relative;
|
||||||
margin-top: 100px;
|
margin-top: 100px;
|
||||||
margin-bottom: 100px;
|
margin-bottom: 100px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 24 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 29 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.center {
|
.center {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 26 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 31 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.left {
|
.left {
|
||||||
text-align: left;
|
text-align: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 28 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 33 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.right {
|
.right {
|
||||||
text-align: right;
|
text-align: right;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 30 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 35 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.italic {
|
.italic {
|
||||||
font-style: italic;
|
font-style: italic;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 32 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 37 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.bold {
|
.bold {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 34 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 39 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.inline {
|
.inline {
|
||||||
display: inline;
|
display: inline;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 36 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 41 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.sixteen.columns {
|
.sixteen.columns {
|
||||||
margin-bottom: 50px;
|
margin-bottom: 50px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 38 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 43 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.section {
|
.section {
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 42 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 47 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
a,
|
a,
|
||||||
a:visited {
|
a:visited {
|
||||||
color: #080;
|
color: #080;
|
||||||
@@ -1261,41 +1309,41 @@ a:visited {
|
|||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 46 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 51 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
|
|
||||||
/* line 47 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 52 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
a:hover,
|
a:hover,
|
||||||
a:focus {
|
a:focus {
|
||||||
color: #040;
|
color: #040;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 49 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 54 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
p a,
|
p a,
|
||||||
p a:visited {
|
p a:visited {
|
||||||
line-height: inherit;
|
line-height: inherit;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 53 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 58 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.indent1 {
|
.indent1 {
|
||||||
margin-left: 10px;
|
margin-left: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 55 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 60 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.indent2 {
|
.indent2 {
|
||||||
margin-left: 20px;
|
margin-left: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 59 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 64 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
code {
|
code {
|
||||||
color: #080;
|
color: #080;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 61 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 66 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
code.black {
|
code.black {
|
||||||
color: #181818;
|
color: #181818;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 64 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 83 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
pre.prettyprint {
|
pre.prettyprint {
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
font-family: 'Droid Sans Mono', Courier;
|
font-family: 'Droid Sans Mono', Courier;
|
||||||
@@ -1309,45 +1357,45 @@ pre.prettyprint {
|
|||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 71 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 90 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
pre.prettyprint.runnable {
|
pre.prettyprint.runnable {
|
||||||
border-left: #080 1px solid;
|
border-left: #080 1px solid;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 74 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 93 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
pre.prettyprint:hover {
|
pre.prettyprint:hover {
|
||||||
background: whiteSmoke;
|
background: whiteSmoke;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 76 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 95 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
pre.prettyprint.running {
|
pre.prettyprint.running {
|
||||||
background: #d3f3d3;
|
background: #d3f3d3;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 80 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 98 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.pos-chooser-dial {
|
.pos-chooser-dial {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 83 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 100 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.box.pos-chooser-demo {
|
.box.pos-chooser-demo {
|
||||||
color: #000;
|
color: #000;
|
||||||
padding: 20px;
|
padding: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 88 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 104 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.entry {
|
.entry {
|
||||||
margin-left: 10px;
|
margin-left: 10px;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 91 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 107 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.entry:hover {
|
.entry:hover {
|
||||||
background: whiteSmoke;
|
background: whiteSmoke;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 95 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 110 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.demo-mouse {
|
.demo-mouse {
|
||||||
position: relative;
|
position: relative;
|
||||||
left: 250px;
|
left: 250px;
|
||||||
@@ -1359,13 +1407,13 @@ pre.prettyprint.running {
|
|||||||
transition: all 1s ease-out;
|
transition: all 1s ease-out;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 98 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 113 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.demo-mouse.over {
|
.demo-mouse.over {
|
||||||
top: -30px;
|
top: -30px;
|
||||||
left: 125px;
|
left: 125px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 102 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 116 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.box {
|
.box {
|
||||||
color: #080;
|
color: #080;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
@@ -1375,7 +1423,7 @@ pre.prettyprint.running {
|
|||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 110 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 123 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.build-tool-toggle {
|
.build-tool-toggle {
|
||||||
margin: 20px;
|
margin: 20px;
|
||||||
display: none;
|
display: none;
|
||||||
@@ -1383,14 +1431,14 @@ pre.prettyprint.running {
|
|||||||
box-shadow: 1px 1px 30px 1px #080;
|
box-shadow: 1px 1px 30px 1px #080;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 115 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 127 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.columns.build-tool {
|
.columns.build-tool {
|
||||||
display: none;
|
display: none;
|
||||||
background: whiteSmoke;
|
background: whiteSmoke;
|
||||||
padding: 25px 25px 5px 25px;
|
padding: 25px 25px 5px 25px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 120 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 131 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.columns.build-tool input,
|
.columns.build-tool input,
|
||||||
.columns.build-tool textarea,
|
.columns.build-tool textarea,
|
||||||
.columns.build-tool button,
|
.columns.build-tool button,
|
||||||
@@ -1398,18 +1446,18 @@ pre.prettyprint.running {
|
|||||||
margin-bottom: 5px;
|
margin-bottom: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 122 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 133 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.columns.build-tool hr {
|
.columns.build-tool hr {
|
||||||
margin-bottom: 15px;
|
margin-bottom: 15px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 125 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 135 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.columns.build-tool select {
|
.columns.build-tool select {
|
||||||
display: inline;
|
display: inline;
|
||||||
height: 32px;
|
height: 32px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 129 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 138 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.columns.build-tool .build-tool-style {
|
.columns.build-tool .build-tool-style {
|
||||||
padding: 3px;
|
padding: 3px;
|
||||||
margin: 5px 0;
|
margin: 5px 0;
|
||||||
@@ -1418,12 +1466,12 @@ pre.prettyprint.running {
|
|||||||
border-radius: 3px;
|
border-radius: 3px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 135 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 143 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.columns.build-tool .build-tool-style .name {
|
.columns.build-tool .build-tool-style .name {
|
||||||
display: inline;
|
display: inline;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 137 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 145 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.columns.build-tool .build-tool-style .name,
|
.columns.build-tool .build-tool-style .name,
|
||||||
.columns.build-tool .build-tool-style .code {
|
.columns.build-tool .build-tool-style .code {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
@@ -1432,13 +1480,58 @@ pre.prettyprint.running {
|
|||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 140 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 148 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.columns.build-tool .build-tool-style .code {
|
.columns.build-tool .build-tool-style .code {
|
||||||
font-family: 'Droid Sans Mono', Courier;
|
font-family: 'Droid Sans Mono', Courier;
|
||||||
height: 215px;
|
height: 215px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 147 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 151 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
|
.notifyjs-gswg-base {
|
||||||
|
font-family: Helvetica, Arial;
|
||||||
|
opacity: 0.85;
|
||||||
|
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=85)";
|
||||||
|
filter: alpha(opacity=85);
|
||||||
|
width: 325px;
|
||||||
|
background: #e48632;
|
||||||
|
padding: 15px;
|
||||||
|
-webkit-border-radius: 10px;
|
||||||
|
border-radius: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* line 158 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
|
|
||||||
|
/* line 159 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
|
.notifyjs-gswg-base .content .cover {
|
||||||
|
float: left;
|
||||||
|
background: url("http://gswg.io/img/cover2.jpg");
|
||||||
|
-webkit-background-size: cover;
|
||||||
|
-moz-background-size: cover;
|
||||||
|
background-size: cover;
|
||||||
|
width: 105px;
|
||||||
|
height: 130px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* line 165 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
|
.notifyjs-gswg-base .content .text {
|
||||||
|
float: left;
|
||||||
|
width: 200px;
|
||||||
|
padding-left: 15px;
|
||||||
|
padding-top: 10px;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* line 171 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
|
.notifyjs-gswg-base .content .text .title {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* line 173 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
|
.notifyjs-gswg-base .content .text button {
|
||||||
|
margin-bottom: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* line 176 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.clearfix:after {
|
.clearfix:after {
|
||||||
visibility: hidden;
|
visibility: hidden;
|
||||||
display: block;
|
display: block;
|
||||||
@@ -1448,20 +1541,20 @@ pre.prettyprint.running {
|
|||||||
height: 0;
|
height: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 155 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 183 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.clearfix {
|
.clearfix {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 157 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 69 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
/* start commented backslash hack \*/
|
/* start commented backslash hack \*/
|
||||||
|
|
||||||
/* line 158 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 186 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
* html .clearfix {
|
* html .clearfix {
|
||||||
height: 1%;
|
height: 1%;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* line 160 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
/* line 188 : /Users/jpillora/Code/JavaScript/notifyjs/docs/src/styles/app.styl */
|
||||||
.clearfix {
|
.clearfix {
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
|||||||
-469
@@ -1,469 +0,0 @@
|
|||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8">
|
|
||||||
<title>Notify.js</title>
|
|
||||||
<meta name="description" content="Notify.js - A simple, versatile notification library">
|
|
||||||
<meta name="author" content="Jaime Pillora <dev@jpillora.com>">
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
|
|
||||||
<link rel="stylesheet" href="docs/css/app.css">
|
|
||||||
<link href="http://fonts.googleapis.com/css?family=Merriweather+Sans:400,300,700,800" rel="stylesheet" type="text/css"><!--[if lt IE 9]>
|
|
||||||
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
|
|
||||||
</head>
|
|
||||||
<body><a href="https://github.com/jpillora/notifyjs"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_green_007200.png" alt="Fork me on GitHub"></a>
|
|
||||||
<div class="main container">
|
|
||||||
<div class="eight columns">
|
|
||||||
<h1 class="title">Notify.js</h1>
|
|
||||||
</div>
|
|
||||||
<div class="eight columns right"><span>
|
|
||||||
<iframe src="http://ghbtns.com/github-btn.html?user=jpillora&type=follow" allowtransparency="true" frameborder="0" scrolling="0" width="130" height="20"></iframe></span><span>
|
|
||||||
<iframe src="http://ghbtns.com/github-btn.html?user=jpillora&repo=notifyjs&type=watch&count=true" allowtransparency="true" frameborder="0" scrolling="0" width="80" height="20"></iframe></span><span><a href="https://twitter.com/share" data-url="http://notifyjs.com" data-text="Notify.js - A simple, versatile notification library" data-hashtags="notifyjs" class="twitter-share-button">Tweet</a>
|
|
||||||
<script>
|
|
||||||
!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="//platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");
|
|
||||||
|
|
||||||
</script></span></div>
|
|
||||||
<hr>
|
|
||||||
<div class="eight columns summary">
|
|
||||||
<h3>Summary</h3>
|
|
||||||
<p>
|
|
||||||
Notify.js is a jQuery plugin to provide simple yet fully customisable notifications.
|
|
||||||
The javascript code snippets in this documentation with the <code>green</code> edge are runnable by clicking them.
|
|
||||||
</p>
|
|
||||||
<p>
|
|
||||||
<pre class="prettyprint runnable">$.notify("Hello World");</pre>
|
|
||||||
</p><img src="docs/img/pointer.png" class="demo-mouse">
|
|
||||||
</div>
|
|
||||||
<div class="eight columns">
|
|
||||||
<h3>Download</h3>
|
|
||||||
<p>Download pre-packaged with the Bootstrap notification style:<br><a href="dist/notify-combined.min.js" data-download data-name="notify.min">
|
|
||||||
<button>Download notify.min.js</button></a><a href="dist/notify-combined.js" data-download data-name="notify">
|
|
||||||
<button>Download notify.js</button></a></p>
|
|
||||||
<p>Or, create a custom build with your own style<br>
|
|
||||||
<button disabled="disabled" class="build-tool-loading">Loading...</button>
|
|
||||||
<button class="build-tool-toggle">Build a custom notify.js</button>
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
<div ng-app ng-controller="BuildController" class="sixteen columns build-tool">
|
|
||||||
<p class="center">Notify.js Core
|
|
||||||
<button disabled="disabled" class="active">Include</button>
|
|
||||||
</p>
|
|
||||||
<hr>
|
|
||||||
<p><span class="bold">Styles </span><br>
|
|
||||||
<div ng-repeat="style in styles" class="build-tool-style">
|
|
||||||
<div>
|
|
||||||
<textarea ng-model="style.code" class="code"></textarea>
|
|
||||||
</div>
|
|
||||||
<div class="right">
|
|
||||||
<button ng-click="active(style,'active')" ng-class="style.active && 'active'">Include</button>
|
|
||||||
<button ng-click="useDefault(style)" ng-class="settings.default == style && 'active'">Default</button>
|
|
||||||
<button ng-click="test($event,style)" class="test">Test</button>
|
|
||||||
<button ng-click="delete($index)">Delete</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="build-tool-controls center">
|
|
||||||
<button ng-click="addStyle()">Add Style</button>
|
|
||||||
<select ng-options="p.name for p in premadeStyles" ng-model="toLoad"></select>
|
|
||||||
<button ng-click="loadStyle()">Load Style</button><span class="italic">Contribute more styles !</span>
|
|
||||||
</div>
|
|
||||||
</p>
|
|
||||||
<hr>
|
|
||||||
<p class="center">Minify
|
|
||||||
<button ng-click="active(settings,'minify')" ng-class="settings.minify && 'active'">Minify this build</button>
|
|
||||||
</p>
|
|
||||||
<hr>
|
|
||||||
<p class="center">
|
|
||||||
<button ng-click="build()" ng-bind="building && 'Building...' || 'Download this build'"></button><span class="italic indent2">Made with <a href="https://github.com/jpillora/compilejs" target="_blank">Compile.js</a></span>
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
<div class="sixteen columns">
|
|
||||||
<h3>Basic Usage</h3>
|
|
||||||
</div>
|
|
||||||
<div class="eight columns">
|
|
||||||
<h4>Element Notifications</h4>
|
|
||||||
<p>You can place notifications on any element:</p>
|
|
||||||
<p>
|
|
||||||
<pre class="prettyprint runnable">$(".elem-demo").notify("Hello Box");</pre>
|
|
||||||
</p>
|
|
||||||
<p class="center">Like this <span class="box elem-demo">box</span></p>
|
|
||||||
</div>
|
|
||||||
<div class="eight columns">
|
|
||||||
<h4>Global Notifications</h4>
|
|
||||||
<p>
|
|
||||||
|
|
||||||
If you don't specify an element, notification
|
|
||||||
will appear in the top left (unless you specify a
|
|
||||||
different position - See <a data-highlight>Positioning</a>)
|
|
||||||
</p>
|
|
||||||
<p>
|
|
||||||
<pre class="prettyprint runnable">$.notify("I'm over here !");</pre>
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
<div class="sixteen columns">
|
|
||||||
<h4>Notification Styles</h4>
|
|
||||||
<p>
|
|
||||||
Each style may define a set of classes to use to substyle the notification.
|
|
||||||
The pre-packaged version includes a bootstrap notification style (see more below in Styling).
|
|
||||||
These classes include:
|
|
||||||
|
|
||||||
</p>
|
|
||||||
<div><span>Success</span>
|
|
||||||
<pre class="prettyprint runnable indent1">$.notify("Access granted", "success");</pre><span>Info</span>
|
|
||||||
<pre class="prettyprint runnable indent1">$.notify("Do not press this button", "info");</pre><span>Warning</span>
|
|
||||||
<pre class="prettyprint runnable indent1">$.notify("Warning: Self-destruct in 3.. 2..", "warn");</pre><span>Error</span>
|
|
||||||
<pre class="prettyprint runnable indent1">$.notify("BOOM!", "error");</pre>
|
|
||||||
</div>
|
|
||||||
<p style="margin-top:10px" class="italic">Note: This page has set the default class to<code>"success"</code> with<code>$.notify.defaults({ className: "success" });</code>.</p>
|
|
||||||
</div>
|
|
||||||
<div id="position" class="sixteen columns">
|
|
||||||
<h3>Positioning</h3>
|
|
||||||
<p>
|
|
||||||
Element notifications and Global notifications can
|
|
||||||
be vertically repositioned to: <code>"top"</code>, <code>"middle" </code>or <code>"bottom" </code>and horozontally repositioned to: <code>"left"</code>, <code>"center" </code>or <code>"right" </code>.
|
|
||||||
</p>
|
|
||||||
<p>
|
|
||||||
<pre class="prettyprint runnable">$(".pos-demo").notify(
|
|
||||||
"I'm left of the box",
|
|
||||||
{ position:"left" }
|
|
||||||
);</pre>
|
|
||||||
</p>
|
|
||||||
<p class="center">We can position the notification around this <span class="box pos-demo">box</span></p>
|
|
||||||
<p style="padding-top: 30px">Use this positioning tool to see all possible position combinations </p>
|
|
||||||
<div style="padding: 30px;">
|
|
||||||
<label for="pos-elem" class="inline">Element</label>
|
|
||||||
<input type="radio" id="pos-elem" value="elem" name="pos-type" checked="checked">
|
|
||||||
<label for="pos-glob" class="inline">Global</label>
|
|
||||||
<input type="radio" id="pos-glob" value="glob" name="pos-type">
|
|
||||||
</div>
|
|
||||||
<div style="margin-left: 60px">
|
|
||||||
<input data-thickness=".3" data-width="100" data-height="100" data-max="12" data-cursor="true" data-fgColor="#080" data-displayInput="false" data-angleOffset="-15" data-linecap="round" class="pos-chooser">
|
|
||||||
</div>
|
|
||||||
<p class="center"><span>An awesome cool </span><span class="box pos-chooser-demo">larrrggggeeee box</span></p>
|
|
||||||
</div>
|
|
||||||
<div class="sixteen columns">
|
|
||||||
<h3>API</h3>
|
|
||||||
<div class="entry">
|
|
||||||
<h5><code class="black">$.notify( </code><code>string|object</code><code class="black">, [ </code><code>options</code><code class="black"> ])</code></h5>
|
|
||||||
<p class="indent1"><code>string|object</code> - global notification data<br><code>options</code> - an options object or class name string </p>
|
|
||||||
</div>
|
|
||||||
<div class="entry">
|
|
||||||
<h5><code class="black">$.notify( </code><code>element</code><code class="black">, </code><code>string|object</code><code class="black">, [ </code><code>options</code><code class="black"> ])</code></h5>
|
|
||||||
<p class="indent1"><code>element</code> - a jquery element<br><code>string|object</code> - element notification data<br><code>options</code> - an options object or class name string </p>
|
|
||||||
</div>
|
|
||||||
<div class="entry">
|
|
||||||
<h5><code class="black">$( </code><code>selector</code><code class="black"> ).notify( </code><code>string|object</code><code class="black">, [ </code><code>options</code><code class="black"> ])</code></h5>
|
|
||||||
<p class="indent1"><code>selector</code> - jquery selector<br><code>string|object</code> - element notification data<br><code>options</code> - an options object or class name string </p>
|
|
||||||
</div>
|
|
||||||
<div class="entry">
|
|
||||||
<h5><code class="black">$.notify.addStyle( </code><code>styleName</code><code class="black">, </code><code>styleDefinition</code><code class="black"> )</code></h5>
|
|
||||||
<p class="indent1"><code>styleName</code> - string (the <b>style</b> option references this name)<br> <code>styleDefinition</code> - style definition object (see <b>Styling</b> below)</p>
|
|
||||||
</div>
|
|
||||||
<div class="entry">
|
|
||||||
<h5><code class="black">$.notify.defaults( </code><code>options</code><code class="black"> )</code></h5>
|
|
||||||
<p class="indent1"><code>options</code> - an options object (updates the defaults listed below) </p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="sixteen columns">
|
|
||||||
<h3>Options</h3>
|
|
||||||
<p>
|
|
||||||
|
|
||||||
The options object listed above are in the form below.
|
|
||||||
This object below is the actual used to check option
|
|
||||||
validity and set defaults.
|
|
||||||
</p>
|
|
||||||
<pre class="prettyprint">{
|
|
||||||
// whether to hide the notification on click
|
|
||||||
clickToHide: true,
|
|
||||||
// whether to auto-hide the notification
|
|
||||||
autoHide: true,
|
|
||||||
// if autoHide, hide after milliseconds
|
|
||||||
autoHideDelay: 5000,
|
|
||||||
// show the arrow pointing at the element
|
|
||||||
arrowShow: true,
|
|
||||||
// arrow size in pixels
|
|
||||||
arrowSize: 5,
|
|
||||||
// default positions
|
|
||||||
elementPosition: 'bottom left',
|
|
||||||
globalPosition: 'top right',
|
|
||||||
// default style
|
|
||||||
style: 'bootstrap',
|
|
||||||
// default class (string or [string])
|
|
||||||
className: 'error',
|
|
||||||
// show animation
|
|
||||||
showAnimation: 'slideDown',
|
|
||||||
// show animation duration
|
|
||||||
showDuration: 400,
|
|
||||||
// hide animation
|
|
||||||
hideAnimation: 'slideUp',
|
|
||||||
// hide animation duration
|
|
||||||
hideDuration: 200,
|
|
||||||
// padding between element and notification
|
|
||||||
gap: 2
|
|
||||||
}
|
|
||||||
</pre>
|
|
||||||
</div>
|
|
||||||
<div class="sixteen columns">
|
|
||||||
<div class="section">
|
|
||||||
<h3>Custom Styling Guide</h3>
|
|
||||||
<p>You can add your own styles to Notify.js with the<code>$.notify.addStyle </code>method. See <a data-highlight>API</a>.</p>
|
|
||||||
<p>Style definition objects are in the form:</p>
|
|
||||||
<pre class="prettyprint">{
|
|
||||||
//required html representing each notification
|
|
||||||
html: "",
|
|
||||||
//optional object to be converted to css
|
|
||||||
classes: {
|
|
||||||
<className>: {
|
|
||||||
<propertyName>: <value>
|
|
||||||
},
|
|
||||||
<className>: {
|
|
||||||
...
|
|
||||||
},
|
|
||||||
...
|
|
||||||
},
|
|
||||||
//optional css to be inserted onto the page
|
|
||||||
css: ""
|
|
||||||
}
|
|
||||||
</pre>
|
|
||||||
<p>
|
|
||||||
<h5 class="inline">html</h5> - If you only have HTML element that you need to modify per
|
|
||||||
notification then you should give this element an attribute of <code>data-notify-text</code> or <code>data-notify-html</code>. Use <code>data-notify-html</code> if you wish to display arbitrary HTML inside the notification,
|
|
||||||
otherwise, use <code>data-notify-text</code> as it is more secure.<br> Otherwise, if you wish to modify multiple HTML elements per
|
|
||||||
notification then you'll need to give each element one of the two
|
|
||||||
attributes above <b>as well as a value</b>. For an example of this see the Advanced Example below.
|
|
||||||
</p>
|
|
||||||
<p>
|
|
||||||
<h5 class="inline">classes</h5> - This object will be used to construct css. It must be in the form described above and there is an example below.
|
|
||||||
</p>
|
|
||||||
<p>
|
|
||||||
<h5 class="inline">css</h5> - This string is simply raw css. Use this property if you want to keep your style definition inside
|
|
||||||
your js files.
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
<div class="section">
|
|
||||||
<h4>Class naming convention</h4>
|
|
||||||
<p>
|
|
||||||
When each notification is constructed, it's container
|
|
||||||
(outer most element defined in your style html) will automatically
|
|
||||||
apply the class:
|
|
||||||
</p>
|
|
||||||
<p><code>notifyjs-<style name>-base</code></p>
|
|
||||||
<p>
|
|
||||||
|
|
||||||
When you use the class name option (<code>className</code>) the class:
|
|
||||||
</p>
|
|
||||||
<p><code>notifyjs-<style name>-<class name></code></p>
|
|
||||||
<p>
|
|
||||||
will be applied. So if you define your styles in an external CSS file or in the style's css
|
|
||||||
property, you must define your CSS rules using this naming convention.
|
|
||||||
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
<div class="section">
|
|
||||||
<h4>Simple Example</h4>
|
|
||||||
<p>If you were to define the style:</p>
|
|
||||||
<pre class="prettyprint auto-run happyblue-example">$.notify.addStyle('happyblue', {
|
|
||||||
html: "<div>☺<span data-notify-text/>☺</div>",
|
|
||||||
classes: {
|
|
||||||
base: {
|
|
||||||
"white-space": "nowrap",
|
|
||||||
"background-color": "lightblue",
|
|
||||||
"padding": "5px"
|
|
||||||
},
|
|
||||||
superblue: {
|
|
||||||
"color": "white",
|
|
||||||
"background-color": "blue"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
</pre>
|
|
||||||
<p>Upon running this code, the <code>classes</code> object in this example will be converted the following css:</p>
|
|
||||||
<pre class="prettyprint lang-css">.notifyjs-happyblue-base {
|
|
||||||
white-space: nowrap;
|
|
||||||
background-color: lightblue;
|
|
||||||
padding: 5px;
|
|
||||||
}
|
|
||||||
.notifyjs-happyblue-superblue {
|
|
||||||
color: white;
|
|
||||||
background-color: blue;
|
|
||||||
}</pre>
|
|
||||||
<p:i>You can confirm this now by inspecting the DOM (look for the tagged style element in the head)</p:i>
|
|
||||||
<p>You can now use your new style with:</p>
|
|
||||||
<pre class="prettyprint runnable">$.notify('hello !!', {
|
|
||||||
style: 'happyblue'
|
|
||||||
});
|
|
||||||
</pre>
|
|
||||||
<p>
|
|
||||||
|
|
||||||
and you can use the <code>superblue</code> class with:
|
|
||||||
</p>
|
|
||||||
<pre class="prettyprint runnable">$.notify('HELLO !!!!', {
|
|
||||||
style: 'happyblue',
|
|
||||||
className: 'superblue'
|
|
||||||
});
|
|
||||||
</pre>
|
|
||||||
</div>
|
|
||||||
<div class="section">
|
|
||||||
<h4>Advanced Example</h4>
|
|
||||||
<p>Say you wanted to use buttons in your notifications then you could do something like:</p>
|
|
||||||
<pre class="prettyprint auto-run button-js-example">//add a new style 'foo'
|
|
||||||
$.notify.addStyle('foo', {
|
|
||||||
html:
|
|
||||||
"<div>" +
|
|
||||||
"<div class='clearfix'>" +
|
|
||||||
"<div class='title' data-notify-html='title'/>" +
|
|
||||||
"<div class='buttons'>" +
|
|
||||||
"<button class='no'>Cancel</button>" +
|
|
||||||
"<button class='yes' data-notify-text='button'></button>" +
|
|
||||||
"</div>" +
|
|
||||||
"</div>" +
|
|
||||||
"</div>"
|
|
||||||
});
|
|
||||||
|
|
||||||
//listen for click events from this style
|
|
||||||
$(document).on('click', '.notifyjs-foo-base .no', function() {
|
|
||||||
//programmatically trigger propogating hide event
|
|
||||||
$(this).trigger('notify-hide');
|
|
||||||
});
|
|
||||||
$(document).on('click', '.notifyjs-foo-base .yes', function() {
|
|
||||||
//show button text
|
|
||||||
alert($(this).text() + " clicked!");
|
|
||||||
//hide notification
|
|
||||||
$(this).trigger('notify-hide');
|
|
||||||
});
|
|
||||||
</pre>
|
|
||||||
<p>
|
|
||||||
|
|
||||||
Notice there is no <code>classes</code> property defined above. Since the CSS in this example is non-trivial, we'll use an exteral CSS file instead:
|
|
||||||
</p>
|
|
||||||
<p class="italic">Note: you could also convert this CSS code to a JavaScript string and use it with the <code>css</code> property. It's not very readable though it's better for distribution.</p>
|
|
||||||
<pre class="prettyprint auto-add foo-css-example lang-css">.notifyjs-foo-base {
|
|
||||||
opacity: 0.85;
|
|
||||||
width: 200px;
|
|
||||||
background: #F5F5F5;
|
|
||||||
padding: 5px;
|
|
||||||
border-radius: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.notifyjs-foo-base .title {
|
|
||||||
width: 100px;
|
|
||||||
float: left;
|
|
||||||
margin: 10px 0 0 10px;
|
|
||||||
text-align: right;
|
|
||||||
}
|
|
||||||
|
|
||||||
.notifyjs-foo-base .buttons {
|
|
||||||
width: 70px;
|
|
||||||
float: right;
|
|
||||||
font-size: 9px;
|
|
||||||
padding: 5px;
|
|
||||||
margin: 2px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.notifyjs-foo-base button {
|
|
||||||
font-size: 9px;
|
|
||||||
padding: 5px;
|
|
||||||
margin: 2px;
|
|
||||||
width: 60px;
|
|
||||||
}
|
|
||||||
</pre>
|
|
||||||
<p>You can now use this style with:</p>
|
|
||||||
<pre class="prettyprint runnable">$.notify({
|
|
||||||
title: 'Would you like some Foo ?',
|
|
||||||
button: 'Confirm'
|
|
||||||
}, {
|
|
||||||
style: 'foo',
|
|
||||||
autoHide: false,
|
|
||||||
clickToHide: false
|
|
||||||
});
|
|
||||||
</pre>
|
|
||||||
</div>
|
|
||||||
<div class="section">
|
|
||||||
<h4>Extra Example</h4>
|
|
||||||
<p>
|
|
||||||
If using the above methods still don't provide you
|
|
||||||
with what you need then you can, pass jQuery objects
|
|
||||||
straight into the notification (provided that the
|
|
||||||
element has the <code>data-notify-html</code> attribute):
|
|
||||||
|
|
||||||
</p>
|
|
||||||
<pre class="prettyprint runnable">var h5 = $("<h5/>").append("You MUST have some Foo !")
|
|
||||||
|
|
||||||
$.notify({
|
|
||||||
title: h5,
|
|
||||||
button: 'YES !'
|
|
||||||
}, {
|
|
||||||
style: 'foo',
|
|
||||||
autoHide: false,
|
|
||||||
clickToHide: false
|
|
||||||
});
|
|
||||||
</pre>
|
|
||||||
</div>
|
|
||||||
<div class="section">
|
|
||||||
<h4>Style List</h4>
|
|
||||||
<p><span>Currently there is only one style available</span>
|
|
||||||
<ul class="square">
|
|
||||||
<li><a href="../../notifyjs/dist/styles/notify-bootstrap.js" target="_blank">notify-bootstrap.js</a></li>
|
|
||||||
</ul>
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="sixteen columns">
|
|
||||||
<h3>Contributing More Styles </h3>
|
|
||||||
<p>
|
|
||||||
|
|
||||||
Contributing more styles is easy!
|
|
||||||
<ol>
|
|
||||||
<li>Click <a href="https://github.com/jpillora/notifyjs/new/master/src/styles" target="_blank">this</a> link</li>
|
|
||||||
<li>Sign into GitHub (if you're not already)</li>
|
|
||||||
<li>Click 'Fork'</li>
|
|
||||||
<li>Enter your new style</li>
|
|
||||||
<li>Click 'Commit New File'</li>
|
|
||||||
<li>Click 'Send Pull Request'!</li>
|
|
||||||
</ol>
|
|
||||||
</p>
|
|
||||||
<p>To get people started with some styles ideas, checkout this <a href="http://mac.appstorm.net/roundups/utilities-roundups/36-sweet-growl-styles-to-keep-your-notifications-snappy/" target="_blank">post on various Growl styles</a>.</p>
|
|
||||||
<p class="italic">
|
|
||||||
Note: If you wish to contribute to the library by fixing bugs or adding features,
|
|
||||||
see the <b>src</b> folder. Also, the source is in CoffeeScript, however, new styles can be either JavaScript or CoffeeScript.
|
|
||||||
I'm using <a href="https://gruntjs.com" target="_blank">Grunt </a> to compile, minify and concat the builds, you can do so with:
|
|
||||||
<ol>
|
|
||||||
<li>Fork <a href="https://github.com/jpillora/notifyjs">https://github.com/jpillora/notifyjs</a></li>
|
|
||||||
<li><code>cd notifyjs</code></li>
|
|
||||||
<li><code>npm install -g grunt-cli</code></li>
|
|
||||||
<li><code>npm install</code></li>
|
|
||||||
<li><code>grunt</code></li>
|
|
||||||
<li>Pull-request ! </li>
|
|
||||||
</ol>
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<script src="//ajax.googleapis.com/ajax/libs/jquery/1/jquery.js"></script>
|
|
||||||
<script src="dist/notify.js"></script>
|
|
||||||
<script src="dist/styles/notify-bootstrap.js" id="bootstrap-style"></script>
|
|
||||||
<script src="docs/js/app.js"></script>
|
|
||||||
<script defered src="http://jpillora.com/compilejs/dist/compile.js"></script>
|
|
||||||
<script defered src="http://jpillora.com/compilejs/dist/tasks/compile.uglify.js"></script>
|
|
||||||
<script defered src="//ajax.googleapis.com/ajax/libs/angularjs/1.1.4/angular.min.js"></script>
|
|
||||||
<script>
|
|
||||||
//async fonts
|
|
||||||
WebFontConfig = { google: { families: [ 'Droid+Sans+Mono::latin' ] } };
|
|
||||||
(function() {
|
|
||||||
var wf = document.createElement('script');
|
|
||||||
wf.src = ('https:' == document.location.protocol ? 'https' : 'http') +
|
|
||||||
'://ajax.googleapis.com/ajax/libs/webfont/1/webfont.js';
|
|
||||||
wf.type = 'text/javascript';
|
|
||||||
wf.async = 'true';
|
|
||||||
var s = document.getElementsByTagName('script')[0];
|
|
||||||
s.parentNode.insertBefore(wf, s);
|
|
||||||
})();
|
|
||||||
//ga
|
|
||||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
|
||||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
|
||||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
|
||||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
|
||||||
ga('create', 'UA-38709761-6', 'notifyjs.com');
|
|
||||||
ga('send', 'pageview');
|
|
||||||
|
|
||||||
|
|
||||||
</script>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
+29
-7
@@ -758,17 +758,22 @@ PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\f\r ]+/,null," \t\r\
|
|||||||
$(".build-tool-loading").hide();
|
$(".build-tool-loading").hide();
|
||||||
$(".build-tool-toggle").show();
|
$(".build-tool-toggle").show();
|
||||||
App.buildTool = $scope;
|
App.buildTool = $scope;
|
||||||
|
$scope.settings = {
|
||||||
|
minify: false,
|
||||||
|
"default": null
|
||||||
|
};
|
||||||
$scope.styles = [];
|
$scope.styles = [];
|
||||||
$scope.addStyle = function(code, premade) {
|
$scope.addStyle = function(code, premade) {
|
||||||
return $scope.styles.push({
|
var style;
|
||||||
|
style = {
|
||||||
active: true,
|
active: true,
|
||||||
code: code,
|
code: code,
|
||||||
premade: premade
|
premade: premade
|
||||||
});
|
|
||||||
};
|
};
|
||||||
$scope.settings = {
|
$scope.styles.push(style);
|
||||||
minify: false,
|
if (!$scope.settings["default"]) {
|
||||||
"default": $scope.styles[0]
|
return $scope.settings["default"] = style;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
$scope.loadStyle = function() {
|
$scope.loadStyle = function() {
|
||||||
var baseUrl, style;
|
var baseUrl, style;
|
||||||
@@ -800,7 +805,7 @@ PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\f\r ]+/,null," \t\r\
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
$scope.premadeStyle = $scope.premadeStyles[0];
|
$scope.premadeStyle = $scope.premadeStyles[0];
|
||||||
$scope.loadStyle;
|
$scope.loadStyle();
|
||||||
$scope.toggle = function() {
|
$scope.toggle = function() {
|
||||||
$(".build-tool-toggle").toggleClass('active');
|
$(".build-tool-toggle").toggleClass('active');
|
||||||
return $(".build-tool").toggle(400);
|
return $(".build-tool").toggle(400);
|
||||||
@@ -817,6 +822,9 @@ PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\f\r ]+/,null," \t\r\
|
|||||||
};
|
};
|
||||||
getStyleName = function(style) {
|
getStyleName = function(style) {
|
||||||
var m;
|
var m;
|
||||||
|
if (!(style != null ? style.code : void 0)) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
m = style.code.match(/\$\.notify\.addStyle\('(["\w-]+)'/);
|
m = style.code.match(/\$\.notify\.addStyle\('(["\w-]+)'/);
|
||||||
if (!m) {
|
if (!m) {
|
||||||
m = style.code.match(/\$\.notify\.addStyle\("(['\w-]+)"/);
|
m = style.code.match(/\$\.notify\.addStyle\("(['\w-]+)"/);
|
||||||
@@ -959,7 +967,21 @@ PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\f\r ]+/,null," \t\r\
|
|||||||
}, 30 * 1000);
|
}, 30 * 1000);
|
||||||
$(document).on('click', '.prettyprint.runnable', runSnippet);
|
$(document).on('click', '.prettyprint.runnable', runSnippet);
|
||||||
$(".prettyprint.auto-run").each(runSnippet);
|
$(".prettyprint.auto-run").each(runSnippet);
|
||||||
return $(".prettyprint.auto-add").each(addCSS);
|
$(".prettyprint.auto-add").each(addCSS);
|
||||||
|
$.notify.addStyle('gswg', {
|
||||||
|
html: "<div>\n <div class=\"content clearfix\">\n <div class=\"cover\"></div>\n <div class=\"text\">\n <div>Checkout</div>\n <div class=\"title\">Getting Started with Grunt: The JavaScript Task Runner</div>\n <div>Get the first chapter for free!</div>\n <div>\n <a target=\"_blank\" href=\"http://gswg.io\">\n <button data-notify-text></button>\n </a>\n <button>No thanks</button>\n </div>\n </div>\n </div>\n</div>"
|
||||||
|
});
|
||||||
|
$(document).on('click', '.notifyjs-gswg-base button', function() {
|
||||||
|
return $(this).trigger('notify-hide');
|
||||||
|
});
|
||||||
|
return setTimeout(function() {
|
||||||
|
return $.notify("http://gswg.io", {
|
||||||
|
position: 'b r',
|
||||||
|
style: 'gswg',
|
||||||
|
autoHideDelay: 10 * 1000,
|
||||||
|
clickToHide: false
|
||||||
|
});
|
||||||
|
}, 15 * 1000);
|
||||||
};
|
};
|
||||||
|
|
||||||
App = App || {};
|
App = App || {};
|
||||||
|
|||||||
@@ -19,21 +19,22 @@ window.BuildController = ($scope,$timeout) ->
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
$(".build-tool-loading").hide()
|
$(".build-tool-loading").hide()
|
||||||
$(".build-tool-toggle").show()
|
$(".build-tool-toggle").show()
|
||||||
|
|
||||||
App.buildTool = $scope
|
App.buildTool = $scope
|
||||||
|
|
||||||
$scope.styles = []
|
|
||||||
$scope.addStyle = (code, premade) ->
|
|
||||||
$scope.styles.push { active: true, code, premade:premade }
|
|
||||||
|
|
||||||
$scope.settings = {
|
$scope.settings = {
|
||||||
minify: false
|
minify: false
|
||||||
default: $scope.styles[0]
|
default: null
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$scope.styles = []
|
||||||
|
$scope.addStyle = (code, premade) ->
|
||||||
|
style = { active: true, code, premade:premade }
|
||||||
|
$scope.styles.push style
|
||||||
|
$scope.settings.default = style unless $scope.settings.default
|
||||||
|
|
||||||
$scope.loadStyle = ->
|
$scope.loadStyle = ->
|
||||||
style = $scope.premadeStyle
|
style = $scope.premadeStyle
|
||||||
return unless style
|
return unless style
|
||||||
@@ -59,7 +60,7 @@ window.BuildController = ($scope,$timeout) ->
|
|||||||
|
|
||||||
#load bootstrap
|
#load bootstrap
|
||||||
$scope.premadeStyle = $scope.premadeStyles[0]
|
$scope.premadeStyle = $scope.premadeStyles[0]
|
||||||
$scope.loadStyle
|
$scope.loadStyle()
|
||||||
|
|
||||||
#angular has loaded
|
#angular has loaded
|
||||||
$scope.toggle = ->
|
$scope.toggle = ->
|
||||||
@@ -79,6 +80,8 @@ window.BuildController = ($scope,$timeout) ->
|
|||||||
$scope.styles.splice i,1
|
$scope.styles.splice i,1
|
||||||
|
|
||||||
getStyleName = (style) ->
|
getStyleName = (style) ->
|
||||||
|
unless style?.code
|
||||||
|
return null
|
||||||
m = style.code.match /\$\.notify\.addStyle\('(["\w-]+)'/
|
m = style.code.match /\$\.notify\.addStyle\('(["\w-]+)'/
|
||||||
unless m
|
unless m
|
||||||
m = style.code.match /\$\.notify\.addStyle\("(['\w-]+)"/
|
m = style.code.match /\$\.notify\.addStyle\("(['\w-]+)"/
|
||||||
|
|||||||
@@ -35,3 +35,30 @@ App.codeRunner = ->
|
|||||||
|
|
||||||
$(".prettyprint.auto-run").each(runSnippet)
|
$(".prettyprint.auto-run").each(runSnippet)
|
||||||
$(".prettyprint.auto-add").each(addCSS)
|
$(".prettyprint.auto-add").each(addCSS)
|
||||||
|
|
||||||
|
#show gswg ad
|
||||||
|
$.notify.addStyle 'gswg',
|
||||||
|
html: """<div>
|
||||||
|
<div class="content clearfix">
|
||||||
|
<div class="cover"></div>
|
||||||
|
<div class="text">
|
||||||
|
<div>Checkout</div>
|
||||||
|
<div class="title">Getting Started with Grunt: The JavaScript Task Runner</div>
|
||||||
|
<div>Get the first chapter for free!</div>
|
||||||
|
<div>
|
||||||
|
<a target="_blank" href="http://gswg.io">
|
||||||
|
<button data-notify-text></button>
|
||||||
|
</a>
|
||||||
|
<button>No thanks</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
"""
|
||||||
|
|
||||||
|
$(document).on 'click', '.notifyjs-gswg-base button', ->
|
||||||
|
$(this).trigger('notify-hide')
|
||||||
|
|
||||||
|
setTimeout ->
|
||||||
|
$.notify("http://gswg.io", {position:'b r', style: 'gswg', autoHideDelay: 10*1000, clickToHide: false})
|
||||||
|
, 15*1000
|
||||||
|
|||||||
@@ -15,6 +15,9 @@ b
|
|||||||
font-weight: bold
|
font-weight: bold
|
||||||
i
|
i
|
||||||
font-style: italic !important
|
font-style: italic !important
|
||||||
|
|
||||||
|
input:focus, button
|
||||||
|
outline none
|
||||||
input[type="radio"],
|
input[type="radio"],
|
||||||
label[for]
|
label[for]
|
||||||
cursor: pointer
|
cursor: pointer
|
||||||
@@ -143,7 +146,30 @@ pre.prettyprint
|
|||||||
font-family: 'Droid Sans Mono', Courier
|
font-family: 'Droid Sans Mono', Courier
|
||||||
height: 215px
|
height: 215px
|
||||||
|
|
||||||
|
.notifyjs-gswg-base
|
||||||
|
font-family Helvetica, Arial
|
||||||
|
opacity 0.85
|
||||||
|
width 325px
|
||||||
|
background #e48632
|
||||||
|
padding 15px
|
||||||
|
border-radius 10px
|
||||||
|
.content
|
||||||
|
.cover
|
||||||
|
float left
|
||||||
|
background url('http://gswg.io/img/cover2.jpg')
|
||||||
|
background-size cover
|
||||||
|
width 105px
|
||||||
|
height 130px
|
||||||
|
.text
|
||||||
|
float left
|
||||||
|
width 200px
|
||||||
|
padding-left 15px
|
||||||
|
padding-top 10px
|
||||||
|
color white
|
||||||
|
.title
|
||||||
|
font-weight bold
|
||||||
|
button
|
||||||
|
margin-bottom 2px
|
||||||
|
|
||||||
//chris coyers clearfix
|
//chris coyers clearfix
|
||||||
.clearfix:after
|
.clearfix:after
|
||||||
|
|||||||
@@ -1,9 +1,6 @@
|
|||||||
!!! 5
|
doctype html
|
||||||
html(lang='en')
|
html(lang='en')
|
||||||
|
|
||||||
dev = env == 'dev'
|
|
||||||
min = dev ? '' : '.min'
|
|
||||||
|
|
||||||
head
|
head
|
||||||
meta(charset='utf-8')
|
meta(charset='utf-8')
|
||||||
title Notify.js
|
title Notify.js
|
||||||
@@ -19,7 +16,7 @@ html(lang='en')
|
|||||||
|
|
||||||
body
|
body
|
||||||
|
|
||||||
a(href="https://github.com/jpillora/notifyjs")
|
a(href="https://github.com/notifyjs/notifyjs")
|
||||||
img(style="position: absolute; top: 0; right: 0; border: 0;",
|
img(style="position: absolute; top: 0; right: 0; border: 0;",
|
||||||
src="https://s3.amazonaws.com/github/ribbons/forkme_right_green_007200.png",
|
src="https://s3.amazonaws.com/github/ribbons/forkme_right_green_007200.png",
|
||||||
alt="Fork me on GitHub")
|
alt="Fork me on GitHub")
|
||||||
@@ -31,10 +28,8 @@ html(lang='en')
|
|||||||
h1.title Notify.js
|
h1.title Notify.js
|
||||||
|
|
||||||
.eight.columns.right
|
.eight.columns.right
|
||||||
span: iframe(src="http://ghbtns.com/github-btn.html?user=jpillora&type=follow",
|
span: iframe(src="http://ghbtns.com/github-btn.html?user=notifyjs&repo=notifyjs&type=watch&count=true",
|
||||||
allowtransparency="true",frameborder="0",scrolling="0",width="130",height="20")
|
allowtransparency="true",frameborder="0",scrolling="0",width="120",height="20")
|
||||||
span: iframe(src="http://ghbtns.com/github-btn.html?user=jpillora&repo=notifyjs&type=watch&count=true",
|
|
||||||
allowtransparency="true",frameborder="0",scrolling="0",width="80",height="20")
|
|
||||||
span
|
span
|
||||||
a.twitter-share-button(href='https://twitter.com/share', data-url='http://notifyjs.com', data-text='Notify.js - A simple, versatile notification library', data-hashtags='notifyjs') Tweet
|
a.twitter-share-button(href='https://twitter.com/share', data-url='http://notifyjs.com', data-text='Notify.js - A simple, versatile notification library', data-hashtags='notifyjs') Tweet
|
||||||
script.
|
script.
|
||||||
@@ -59,8 +54,8 @@ html(lang='en')
|
|||||||
script(src="docs/js/app.js")
|
script(src="docs/js/app.js")
|
||||||
|
|
||||||
//- build tool scripts
|
//- build tool scripts
|
||||||
script(defered, src="#{false ? '../' : 'http://jpillora.com/'}compilejs/dist/compile.js")
|
script(defered, src="http://jpillora.com/compilejs/dist/compile.js")
|
||||||
script(defered, src="#{false ? '../' : 'http://jpillora.com/'}compilejs/dist/tasks/compile.uglify.js")
|
script(defered, src="http://jpillora.com/compilejs/dist/tasks/compile.uglify.js")
|
||||||
script(defered, src="//ajax.googleapis.com/ajax/libs/angularjs/1.1.4/angular.min.js")
|
script(defered, src="//ajax.googleapis.com/ajax/libs/angularjs/1.1.4/angular.min.js")
|
||||||
|
|
||||||
script.
|
script.
|
||||||
@@ -82,5 +77,3 @@ html(lang='en')
|
|||||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||||
ga('create', 'UA-38709761-6', 'notifyjs.com');
|
ga('create', 'UA-38709761-6', 'notifyjs.com');
|
||||||
ga('send', 'pageview');
|
ga('send', 'pageview');
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
| Contributing more styles is easy!
|
| Contributing more styles is easy!
|
||||||
ol
|
ol
|
||||||
li.
|
li.
|
||||||
Click <a href="https://github.com/jpillora/notifyjs/new/gh-pages/src/styles" target="_blank">this</a> link
|
Click <a href="https://github.com/notifyjs/notifyjs/new/gh-pages/src/styles" target="_blank">this</a> link
|
||||||
li Sign into GitHub (if you're not already)
|
li Sign into GitHub (if you're not already)
|
||||||
li Click 'Fork'
|
li Click 'Fork'
|
||||||
li Enter your new style
|
li Enter your new style
|
||||||
@@ -31,7 +31,7 @@
|
|||||||
ol
|
ol
|
||||||
li
|
li
|
||||||
| Fork
|
| Fork
|
||||||
a(href="https://github.com/jpillora/notifyjs") https://github.com/jpillora/notifyjs
|
a(href="https://github.com/notifyjs/notifyjs") https://github.com/notifyjs/notifyjs
|
||||||
li: code cd notifyjs
|
li: code cd notifyjs
|
||||||
li: code npm install -g grunt-cli
|
li: code npm install -g grunt-cli
|
||||||
li: code npm install
|
li: code npm install
|
||||||
|
|||||||
@@ -249,7 +249,7 @@
|
|||||||
|
|
||||||
p
|
p
|
||||||
ul.square
|
ul.square
|
||||||
li: a(href="https://github.com/jpillora/notifyjs/tree/gh-pages/dist/styles/bootstrap", target="_blank") bootstrap
|
li: a(href="https://github.com/notifyjs/notifyjs/tree/gh-pages/dist/styles/bootstrap", target="_blank") bootstrap
|
||||||
ul.square
|
ul.square
|
||||||
li: a(href="https://github.com/jpillora/notifyjs/tree/gh-pages/dist/styles/metro", target="_blank") metro
|
li: a(href="https://github.com/notifyjs/notifyjs/tree/gh-pages/dist/styles/metro", target="_blank") metro
|
||||||
|
|
||||||
|
|||||||
+15
-28
@@ -7,17 +7,19 @@
|
|||||||
<meta name="author" content="Jaime Pillora <dev@jpillora.com>">
|
<meta name="author" content="Jaime Pillora <dev@jpillora.com>">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
|
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
|
||||||
<link rel="stylesheet" href="docs/css/app.css">
|
<link rel="stylesheet" href="docs/css/app.css">
|
||||||
<link href="http://fonts.googleapis.com/css?family=Merriweather+Sans:400,300,700,800" rel="stylesheet" type="text/css"><!--[if lt IE 9]>
|
<link href="http://fonts.googleapis.com/css?family=Merriweather+Sans:400,300,700,800" rel="stylesheet" type="text/css">
|
||||||
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
|
<!--if lt IE 9
|
||||||
|
script(src='http://html5shim.googlecode.com/svn/trunk/html5.js')
|
||||||
|
|
||||||
|
-->
|
||||||
</head>
|
</head>
|
||||||
<body><a href="https://github.com/jpillora/notifyjs"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_green_007200.png" alt="Fork me on GitHub"></a>
|
<body><a href="https://github.com/notifyjs/notifyjs"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_green_007200.png" alt="Fork me on GitHub"></a>
|
||||||
<div class="main container">
|
<div class="main container">
|
||||||
<div class="eight columns">
|
<div class="eight columns">
|
||||||
<h1 class="title">Notify.js</h1>
|
<h1 class="title">Notify.js</h1>
|
||||||
</div>
|
</div>
|
||||||
<div class="eight columns right"><span>
|
<div class="eight columns right"><span>
|
||||||
<iframe src="http://ghbtns.com/github-btn.html?user=jpillora&type=follow" allowtransparency="true" frameborder="0" scrolling="0" width="130" height="20"></iframe></span><span>
|
<iframe src="http://ghbtns.com/github-btn.html?user=notifyjs&repo=notifyjs&type=watch&count=true" allowtransparency="true" frameborder="0" scrolling="0" width="120" height="20"></iframe></span><span><a href="https://twitter.com/share" data-url="http://notifyjs.com" data-text="Notify.js - A simple, versatile notification library" data-hashtags="notifyjs" class="twitter-share-button">Tweet</a>
|
||||||
<iframe src="http://ghbtns.com/github-btn.html?user=jpillora&repo=notifyjs&type=watch&count=true" allowtransparency="true" frameborder="0" scrolling="0" width="80" height="20"></iframe></span><span><a href="https://twitter.com/share" data-url="http://notifyjs.com" data-text="Notify.js - A simple, versatile notification library" data-hashtags="notifyjs" class="twitter-share-button">Tweet</a>
|
|
||||||
<script>
|
<script>
|
||||||
!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="//platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");
|
!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="//platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");
|
||||||
|
|
||||||
@@ -90,7 +92,6 @@
|
|||||||
<div class="eight columns">
|
<div class="eight columns">
|
||||||
<h4>Global Notifications</h4>
|
<h4>Global Notifications</h4>
|
||||||
<p>
|
<p>
|
||||||
|
|
||||||
If you don't specify an element, notification
|
If you don't specify an element, notification
|
||||||
will appear in the top left (unless you specify a
|
will appear in the top left (unless you specify a
|
||||||
different position - See <a data-highlight>Positioning</a>)
|
different position - See <a data-highlight>Positioning</a>)
|
||||||
@@ -166,7 +167,6 @@
|
|||||||
<div class="sixteen columns">
|
<div class="sixteen columns">
|
||||||
<h3>Options</h3>
|
<h3>Options</h3>
|
||||||
<p>
|
<p>
|
||||||
|
|
||||||
The options object listed above are in the form below.
|
The options object listed above are in the form below.
|
||||||
This object below is the actual used to check option
|
This object below is the actual used to check option
|
||||||
validity and set defaults.
|
validity and set defaults.
|
||||||
@@ -247,10 +247,7 @@
|
|||||||
apply the class:
|
apply the class:
|
||||||
</p>
|
</p>
|
||||||
<p><code>notifyjs-<style name>-base</code></p>
|
<p><code>notifyjs-<style name>-base</code></p>
|
||||||
<p>
|
<p>When you use the class name option (<code>className</code>) the class:</p>
|
||||||
|
|
||||||
When you use the class name option (<code>className</code>) the class:
|
|
||||||
</p>
|
|
||||||
<p><code>notifyjs-<style name>-<class name></code></p>
|
<p><code>notifyjs-<style name>-<class name></code></p>
|
||||||
<p>
|
<p>
|
||||||
will be applied. So if you define your styles in an external CSS file or in the style's css
|
will be applied. So if you define your styles in an external CSS file or in the style's css
|
||||||
@@ -292,10 +289,7 @@
|
|||||||
style: 'happyblue'
|
style: 'happyblue'
|
||||||
});
|
});
|
||||||
</pre>
|
</pre>
|
||||||
<p>
|
<p>and you can use the <code>superblue</code> class with:</p>
|
||||||
|
|
||||||
and you can use the <code>superblue</code> class with:
|
|
||||||
</p>
|
|
||||||
<pre class="prettyprint runnable">$.notify('HELLO !!!!', {
|
<pre class="prettyprint runnable">$.notify('HELLO !!!!', {
|
||||||
style: 'happyblue',
|
style: 'happyblue',
|
||||||
className: 'superblue'
|
className: 'superblue'
|
||||||
@@ -331,10 +325,7 @@ $(document).on('click', '.notifyjs-foo-base .yes', function() {
|
|||||||
$(this).trigger('notify-hide');
|
$(this).trigger('notify-hide');
|
||||||
});
|
});
|
||||||
</pre>
|
</pre>
|
||||||
<p>
|
<p>Notice there is no <code>classes</code> property defined above. Since the CSS in this example is non-trivial, we'll use an exteral CSS file instead:</p>
|
||||||
|
|
||||||
Notice there is no <code>classes</code> property defined above. Since the CSS in this example is non-trivial, we'll use an exteral CSS file instead:
|
|
||||||
</p>
|
|
||||||
<p class="italic">Note: you could also convert this CSS code to a JavaScript string and use it with the <code>css</code> property. It's not very readable though it's better for distribution.</p>
|
<p class="italic">Note: you could also convert this CSS code to a JavaScript string and use it with the <code>css</code> property. It's not very readable though it's better for distribution.</p>
|
||||||
<pre class="prettyprint auto-add foo-css-example lang-css">.notifyjs-foo-base {
|
<pre class="prettyprint auto-add foo-css-example lang-css">.notifyjs-foo-base {
|
||||||
opacity: 0.85;
|
opacity: 0.85;
|
||||||
@@ -402,21 +393,19 @@ $.notify({
|
|||||||
<h4>Style List</h4>
|
<h4>Style List</h4>
|
||||||
<p>
|
<p>
|
||||||
<ul class="square">
|
<ul class="square">
|
||||||
<li><a href="https://github.com/jpillora/notifyjs/tree/gh-pages/dist/styles/bootstrap" target="_blank">bootstrap</a></li>
|
<li><a href="https://github.com/notifyjs/notifyjs/tree/gh-pages/dist/styles/bootstrap" target="_blank">bootstrap</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
<ul class="square">
|
<ul class="square">
|
||||||
<li><a href="https://github.com/jpillora/notifyjs/tree/gh-pages/dist/styles/metro" target="_blank">metro</a></li>
|
<li><a href="https://github.com/notifyjs/notifyjs/tree/gh-pages/dist/styles/metro" target="_blank">metro</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="sixteen columns">
|
<div class="sixteen columns">
|
||||||
<h3>Contributing More Styles </h3>
|
<h3>Contributing More Styles </h3>
|
||||||
<p>
|
<p>Contributing more styles is easy!
|
||||||
|
|
||||||
Contributing more styles is easy!
|
|
||||||
<ol>
|
<ol>
|
||||||
<li>Click <a href="https://github.com/jpillora/notifyjs/new/gh-pages/src/styles" target="_blank">this</a> link</li>
|
<li>Click <a href="https://github.com/notifyjs/notifyjs/new/gh-pages/src/styles" target="_blank">this</a> link</li>
|
||||||
<li>Sign into GitHub (if you're not already)</li>
|
<li>Sign into GitHub (if you're not already)</li>
|
||||||
<li>Click 'Fork'</li>
|
<li>Click 'Fork'</li>
|
||||||
<li>Enter your new style</li>
|
<li>Enter your new style</li>
|
||||||
@@ -430,7 +419,7 @@ $.notify({
|
|||||||
see the <b>src</b> folder. Also, the source is in CoffeeScript, however, new styles can be either JavaScript or CoffeeScript.
|
see the <b>src</b> folder. Also, the source is in CoffeeScript, however, new styles can be either JavaScript or CoffeeScript.
|
||||||
I'm using <a href="https://gruntjs.com" target="_blank">Grunt </a> to compile, minify and concat the builds, you can do so with:
|
I'm using <a href="https://gruntjs.com" target="_blank">Grunt </a> to compile, minify and concat the builds, you can do so with:
|
||||||
<ol>
|
<ol>
|
||||||
<li>Fork <a href="https://github.com/jpillora/notifyjs">https://github.com/jpillora/notifyjs</a></li>
|
<li>Fork <a href="https://github.com/notifyjs/notifyjs">https://github.com/notifyjs/notifyjs</a></li>
|
||||||
<li><code>cd notifyjs</code></li>
|
<li><code>cd notifyjs</code></li>
|
||||||
<li><code>npm install -g grunt-cli</code></li>
|
<li><code>npm install -g grunt-cli</code></li>
|
||||||
<li><code>npm install</code></li>
|
<li><code>npm install</code></li>
|
||||||
@@ -466,8 +455,6 @@ $.notify({
|
|||||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||||
ga('create', 'UA-38709761-6', 'notifyjs.com');
|
ga('create', 'UA-38709761-6', 'notifyjs.com');
|
||||||
ga('send', 'pageview');
|
ga('send', 'pageview');
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "notify",
|
"name": "notify",
|
||||||
"version": "0.3.1",
|
"version": "0.3.2",
|
||||||
"title": "notify",
|
"title": "notify",
|
||||||
"description": "A robust, customizable notification library",
|
"description": "A robust, customizable notification library",
|
||||||
"bugs": "https://github.com/jpillora/notifyjs/issues",
|
"bugs": "https://github.com/jpillora/notifyjs/issues",
|
||||||
|
|||||||
+9
-13
@@ -1,22 +1,18 @@
|
|||||||
{
|
{
|
||||||
"title": "Notify.js",
|
"title": "Notify.js",
|
||||||
"name": "notify",
|
"name": "notify",
|
||||||
"version": "0.3.1",
|
"version": "0.3.3",
|
||||||
"author": {
|
"author": {
|
||||||
"name": "Jaime Pillora"
|
"name": "Jaime Pillora"
|
||||||
},
|
},
|
||||||
|
"contributors": [
|
||||||
|
{
|
||||||
|
"name": "Evan Carroll"
|
||||||
|
, "url": "http://www.evancarroll.com"
|
||||||
|
, "email": "me@evancarroll.com"
|
||||||
|
}
|
||||||
|
],
|
||||||
"homepage": "http://notifyjs.com/",
|
"homepage": "http://notifyjs.com/",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"devDependencies": {
|
"main": "dist/notify.js"
|
||||||
"grunt": "~0.4.x",
|
|
||||||
"grunt-contrib-watch": "~0.1.4",
|
|
||||||
"grunt-contrib-uglify": "~0.1.1rc6",
|
|
||||||
"grunt-contrib-jshint": "~0.1.0",
|
|
||||||
"grunt-contrib-concat": "~0.1.1",
|
|
||||||
"grunt-contrib-coffee": "~0.4.0rc7",
|
|
||||||
"grunt-wrap": "~0.2.0"
|
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"grunt-contrib-concat": "~0.3.0"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,566 +0,0 @@
|
|||||||
|
|
||||||
'use strict'
|
|
||||||
|
|
||||||
#plugin constants
|
|
||||||
pluginName = 'notify'
|
|
||||||
pluginClassName = pluginName+'js'
|
|
||||||
blankFieldName = pluginName+"!blank"
|
|
||||||
|
|
||||||
# ================================
|
|
||||||
# POSITIONING
|
|
||||||
# ================================
|
|
||||||
|
|
||||||
positions =
|
|
||||||
t: 'top'
|
|
||||||
m: 'middle'
|
|
||||||
b: 'bottom'
|
|
||||||
l: 'left'
|
|
||||||
c: 'center'
|
|
||||||
r: 'right'
|
|
||||||
hAligns = ['l','c','r']
|
|
||||||
vAligns = ['t','m','b']
|
|
||||||
mainPositions = ['t','b','l','r']
|
|
||||||
#positions mapped to opposites
|
|
||||||
opposites =
|
|
||||||
t: 'b'
|
|
||||||
m: null
|
|
||||||
b: 't'
|
|
||||||
l: 'r'
|
|
||||||
c: null
|
|
||||||
r: 'l'
|
|
||||||
|
|
||||||
parsePosition = (str) ->
|
|
||||||
pos = []
|
|
||||||
$.each str.split(/\W+/), (i,word) ->
|
|
||||||
w = word.toLowerCase().charAt(0)
|
|
||||||
pos.push w if positions[w]
|
|
||||||
pos
|
|
||||||
|
|
||||||
# ================================
|
|
||||||
# STYLES
|
|
||||||
# ================================
|
|
||||||
styles = {}
|
|
||||||
|
|
||||||
coreStyle =
|
|
||||||
name: 'core'
|
|
||||||
html: """
|
|
||||||
<div class="#{pluginClassName}-wrapper">
|
|
||||||
<div class="#{pluginClassName}-arrow"></div>
|
|
||||||
<div class="#{pluginClassName}-container"></div>
|
|
||||||
</div>
|
|
||||||
"""
|
|
||||||
# <div class="#{pluginClassName}-debug"></div>
|
|
||||||
# .#{pluginClassName}-debug {
|
|
||||||
# position: absolute;
|
|
||||||
# border: 3px solid red;
|
|
||||||
# height: 0;
|
|
||||||
# width: 0;
|
|
||||||
# }
|
|
||||||
css: """
|
|
||||||
.#{pluginClassName}-corner {
|
|
||||||
position: fixed;
|
|
||||||
margin: 5px;
|
|
||||||
z-index: 1050;
|
|
||||||
}
|
|
||||||
|
|
||||||
.#{pluginClassName}-corner .#{pluginClassName}-wrapper,
|
|
||||||
.#{pluginClassName}-corner .#{pluginClassName}-container {
|
|
||||||
position: relative;
|
|
||||||
display: block;
|
|
||||||
height: inherit;
|
|
||||||
width: inherit;
|
|
||||||
margin: 3px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.#{pluginClassName}-wrapper {
|
|
||||||
z-index: 1;
|
|
||||||
position: absolute;
|
|
||||||
display: inline-block;
|
|
||||||
height: 0;
|
|
||||||
width: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.#{pluginClassName}-container {
|
|
||||||
display: none;
|
|
||||||
z-index: 1;
|
|
||||||
position: absolute;
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
|
|
||||||
[data-notify-text],[data-notify-html] {
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
|
|
||||||
.#{pluginClassName}-arrow {
|
|
||||||
position: absolute;
|
|
||||||
z-index: 2;
|
|
||||||
width: 0;
|
|
||||||
height: 0;
|
|
||||||
}
|
|
||||||
"""
|
|
||||||
|
|
||||||
stylePrefixes =
|
|
||||||
"border-radius": ["-webkit-", "-moz-"]
|
|
||||||
|
|
||||||
getStyle = (name) ->
|
|
||||||
styles[name]
|
|
||||||
|
|
||||||
addStyle = (name, def) ->
|
|
||||||
|
|
||||||
unless name
|
|
||||||
throw "Missing Style name"
|
|
||||||
unless def
|
|
||||||
throw "Missing Style definition"
|
|
||||||
unless def.html
|
|
||||||
throw "Missing Style HTML"
|
|
||||||
|
|
||||||
if styles[name]?.cssElem
|
|
||||||
if window.console
|
|
||||||
console.warn "#{pluginName}: overwriting style '#{name}'"
|
|
||||||
styles[name].cssElem.remove()
|
|
||||||
|
|
||||||
def.name = name
|
|
||||||
styles[name] = def
|
|
||||||
|
|
||||||
cssText = ""
|
|
||||||
if def.classes
|
|
||||||
$.each def.classes, (className, props) ->
|
|
||||||
cssText += ".#{pluginClassName}-#{def.name}-#{className} {\n"
|
|
||||||
$.each props, (name, val) ->
|
|
||||||
#vendor prefixes
|
|
||||||
if stylePrefixes[name]
|
|
||||||
$.each stylePrefixes[name], (i, prefix) ->
|
|
||||||
cssText += " #{prefix}#{name}: #{val};\n"
|
|
||||||
#add prop
|
|
||||||
cssText += " #{name}: #{val};\n"
|
|
||||||
cssText += "}\n"
|
|
||||||
if def.css
|
|
||||||
cssText += """
|
|
||||||
/* styles for #{def.name} */
|
|
||||||
#{def.css}
|
|
||||||
"""
|
|
||||||
|
|
||||||
if cssText
|
|
||||||
def.cssElem = insertCSS cssText
|
|
||||||
def.cssElem.attr('id', "notify-#{def.name}")
|
|
||||||
|
|
||||||
#precompute usable text fields
|
|
||||||
fields = {}
|
|
||||||
elem = $(def.html)
|
|
||||||
findFields 'html', elem, fields
|
|
||||||
findFields 'text', elem, fields
|
|
||||||
def.fields = fields
|
|
||||||
|
|
||||||
insertCSS = (cssText) ->
|
|
||||||
|
|
||||||
elem = createElem("style")
|
|
||||||
elem.attr 'type', 'text/css'
|
|
||||||
$("head").append elem
|
|
||||||
try
|
|
||||||
elem.html cssText
|
|
||||||
catch e #ie fix
|
|
||||||
elem[0].styleSheet.cssText = cssText
|
|
||||||
elem
|
|
||||||
|
|
||||||
# style.html helper
|
|
||||||
findFields = (type, elem, fields) ->
|
|
||||||
type = 'text' if type isnt 'html'
|
|
||||||
attr = "data-notify-#{type}"
|
|
||||||
find(elem,"[#{attr}]").each ->
|
|
||||||
name = $(@).attr attr
|
|
||||||
name = blankFieldName unless name
|
|
||||||
fields[name] = type
|
|
||||||
|
|
||||||
find = (elem, selector) ->
|
|
||||||
if elem.is(selector) then elem else elem.find selector
|
|
||||||
|
|
||||||
# ================================
|
|
||||||
# OPTIONS
|
|
||||||
# ================================
|
|
||||||
|
|
||||||
#overridable options
|
|
||||||
pluginOptions =
|
|
||||||
clickToHide: true
|
|
||||||
autoHide: true
|
|
||||||
autoHideDelay: 5000
|
|
||||||
arrowShow: true
|
|
||||||
arrowSize: 5
|
|
||||||
breakNewLines: true
|
|
||||||
# autoReposition: true
|
|
||||||
elementPosition: 'bottom'
|
|
||||||
globalPosition: 'top right'
|
|
||||||
style: 'bootstrap'
|
|
||||||
className: 'error'
|
|
||||||
showAnimation: 'slideDown'
|
|
||||||
showDuration: 400
|
|
||||||
hideAnimation: 'slideUp'
|
|
||||||
hideDuration: 200
|
|
||||||
gap: 5
|
|
||||||
|
|
||||||
inherit = (a, b) ->
|
|
||||||
F = () ->
|
|
||||||
F.prototype = a
|
|
||||||
$.extend true, new F(), b
|
|
||||||
|
|
||||||
defaults = (opts) ->
|
|
||||||
$.extend pluginOptions, opts
|
|
||||||
|
|
||||||
# ================================
|
|
||||||
# DOM MANIPULATION
|
|
||||||
# ================================
|
|
||||||
|
|
||||||
# plugin helpers
|
|
||||||
createElem = (tag) ->
|
|
||||||
$ "<#{tag}></#{tag}>"
|
|
||||||
|
|
||||||
# references to global anchor positions
|
|
||||||
globalAnchors = {}
|
|
||||||
|
|
||||||
#gets first on n radios, and gets the fancy stylised input for hidden inputs
|
|
||||||
getAnchorElement = (element) ->
|
|
||||||
#choose the first of n radios
|
|
||||||
if element.is('[type=radio]')
|
|
||||||
radios = element.parents('form:first').find('[type=radio]').filter (i, e) ->
|
|
||||||
$(e).attr('name') is element.attr('name')
|
|
||||||
element = radios.first()
|
|
||||||
#custom-styled inputs - find thier real element
|
|
||||||
element
|
|
||||||
|
|
||||||
incr = (obj, pos, val) ->
|
|
||||||
# console.log "incr ---- #{pos} #{val} (#{typeof val})"
|
|
||||||
if typeof val is 'string'
|
|
||||||
val = parseInt val, 10
|
|
||||||
else if typeof val isnt 'number'
|
|
||||||
return
|
|
||||||
|
|
||||||
return if isNaN val
|
|
||||||
|
|
||||||
opp = positions[opposites[pos.charAt(0)]]
|
|
||||||
temp = pos
|
|
||||||
|
|
||||||
#use the opposite if exists
|
|
||||||
if obj[opp] isnt `undefined`
|
|
||||||
pos = positions[opp.charAt(0)]
|
|
||||||
val = -val
|
|
||||||
|
|
||||||
if obj[pos] is `undefined`
|
|
||||||
obj[pos] = val
|
|
||||||
else
|
|
||||||
obj[pos] += val
|
|
||||||
null
|
|
||||||
|
|
||||||
realign = (alignment, inner, outer) ->
|
|
||||||
return if alignment in ['l','t']
|
|
||||||
0
|
|
||||||
else if alignment in ['c','m']
|
|
||||||
outer/2 - inner/2
|
|
||||||
else if alignment in ['r','b']
|
|
||||||
outer - inner
|
|
||||||
throw "Invalid alignment"
|
|
||||||
|
|
||||||
encode = (text) ->
|
|
||||||
encode.e = encode.e or createElem "div"
|
|
||||||
encode.e.text(text).html()
|
|
||||||
|
|
||||||
# ================================
|
|
||||||
# NOTIFY CLASS
|
|
||||||
# ================================
|
|
||||||
|
|
||||||
#define plugin
|
|
||||||
class Notification
|
|
||||||
|
|
||||||
#setup instance variables
|
|
||||||
constructor: (elem, data, options) ->
|
|
||||||
options = {className: options} if typeof options is 'string'
|
|
||||||
@options = inherit pluginOptions, if $.isPlainObject(options) then options else {}
|
|
||||||
|
|
||||||
#load style html into @userContainer
|
|
||||||
@loadHTML()
|
|
||||||
|
|
||||||
@wrapper = $(coreStyle.html)
|
|
||||||
@wrapper.data pluginClassName, @
|
|
||||||
@arrow = @wrapper.find ".#{pluginClassName}-arrow"
|
|
||||||
@container = @wrapper.find ".#{pluginClassName}-container"
|
|
||||||
@container.append @userContainer
|
|
||||||
|
|
||||||
if elem and elem.length
|
|
||||||
@elementType = elem.attr('type')
|
|
||||||
@originalElement = elem
|
|
||||||
@elem = getAnchorElement(elem)
|
|
||||||
@elem.data pluginClassName, @
|
|
||||||
# add into dom above elem
|
|
||||||
@elem.before @wrapper
|
|
||||||
|
|
||||||
@container.hide()
|
|
||||||
@run(data)
|
|
||||||
|
|
||||||
loadHTML: ->
|
|
||||||
style = @getStyle()
|
|
||||||
@userContainer = $(style.html)
|
|
||||||
@userFields = style.fields
|
|
||||||
|
|
||||||
show: (show, userCallback) ->
|
|
||||||
|
|
||||||
callback = =>
|
|
||||||
@destroy() if not show and not @elem
|
|
||||||
userCallback() if userCallback
|
|
||||||
|
|
||||||
hidden = @container.parent().parents(':hidden').length > 0
|
|
||||||
|
|
||||||
elems = @container.add @arrow
|
|
||||||
args = []
|
|
||||||
|
|
||||||
if hidden and show
|
|
||||||
fn = 'show'
|
|
||||||
else if hidden and not show
|
|
||||||
fn = 'hide'
|
|
||||||
else if not hidden and show
|
|
||||||
fn = @options.showAnimation
|
|
||||||
args.push @options.showDuration
|
|
||||||
else if not hidden and not show
|
|
||||||
fn = @options.hideAnimation
|
|
||||||
args.push @options.hideDuration
|
|
||||||
else
|
|
||||||
return callback()
|
|
||||||
|
|
||||||
args.push callback
|
|
||||||
|
|
||||||
elems[fn].apply elems, args
|
|
||||||
|
|
||||||
|
|
||||||
setGlobalPosition: () ->
|
|
||||||
[pMain, pAlign] = @getPosition()
|
|
||||||
|
|
||||||
main = positions[pMain]
|
|
||||||
align = positions[pAlign]
|
|
||||||
|
|
||||||
key = pMain+"|"+pAlign
|
|
||||||
anchor = globalAnchors[key]
|
|
||||||
unless anchor
|
|
||||||
anchor = globalAnchors[key] = createElem("div")
|
|
||||||
css = {}
|
|
||||||
css[main] = 0
|
|
||||||
if align is 'middle'
|
|
||||||
css.top = '45%'
|
|
||||||
else if align is 'center'
|
|
||||||
css.left = '45%'
|
|
||||||
else
|
|
||||||
css[align] = 0
|
|
||||||
anchor.css(css).addClass("#{pluginClassName}-corner")
|
|
||||||
$("body").append anchor
|
|
||||||
|
|
||||||
anchor.prepend @wrapper
|
|
||||||
|
|
||||||
setElementPosition: () ->
|
|
||||||
position = @getPosition()
|
|
||||||
|
|
||||||
[pMain, pAlign, pArrow] = position
|
|
||||||
|
|
||||||
#grab some dimensions
|
|
||||||
elemPos = @elem.position()
|
|
||||||
elemH = @elem.outerHeight()
|
|
||||||
elemW = @elem.outerWidth()
|
|
||||||
elemIH = @elem.innerHeight()
|
|
||||||
elemIW = @elem.innerWidth()
|
|
||||||
wrapPos = @wrapper.position()
|
|
||||||
contH = @container.height()
|
|
||||||
contW = @container.width()
|
|
||||||
|
|
||||||
|
|
||||||
#start calculations
|
|
||||||
mainFull = positions[pMain]
|
|
||||||
opp = opposites[pMain]
|
|
||||||
oppFull = positions[opp]
|
|
||||||
#initial positioning
|
|
||||||
css = {}
|
|
||||||
css[oppFull] = if pMain is 'b'
|
|
||||||
elemH
|
|
||||||
else if pMain is 'r'
|
|
||||||
elemW
|
|
||||||
else
|
|
||||||
0
|
|
||||||
|
|
||||||
#correct for elem-wrapper offset
|
|
||||||
# unless navigator.userAgent.match /MSIE/
|
|
||||||
incr css, 'top', elemPos.top - wrapPos.top
|
|
||||||
incr css, 'left', elemPos.left - wrapPos.left
|
|
||||||
|
|
||||||
#correct for margins
|
|
||||||
for pos in ['top', 'left']
|
|
||||||
margin = parseInt @elem.css("margin-#{pos}"), 10
|
|
||||||
incr css, pos, margin if margin
|
|
||||||
#correct for paddings (only for inline)
|
|
||||||
# if /^inline/.test @elem.css('display')
|
|
||||||
# padding = parseInt @elem.css("padding-#{pos}"), 10
|
|
||||||
# incr css, pos, -padding if padding
|
|
||||||
|
|
||||||
#add gap
|
|
||||||
gap = Math.max 0, @options.gap - if @options.arrowShow then arrowSize else 0
|
|
||||||
incr css, oppFull, gap
|
|
||||||
|
|
||||||
#calculate arrow
|
|
||||||
if not @options.arrowShow
|
|
||||||
@arrow.hide()
|
|
||||||
else
|
|
||||||
arrowSize = @options.arrowSize
|
|
||||||
arrowCss = $.extend {}, css
|
|
||||||
arrowColor = @userContainer.css("border-color") or
|
|
||||||
@userContainer.css("background-color") or
|
|
||||||
'white'
|
|
||||||
#build arrow
|
|
||||||
for pos in mainPositions
|
|
||||||
posFull = positions[pos]
|
|
||||||
continue if pos is opp
|
|
||||||
color = if posFull is mainFull then arrowColor else 'transparent'
|
|
||||||
arrowCss["border-#{posFull}"] = "#{arrowSize}px solid #{color}"
|
|
||||||
#add some room for the arrow
|
|
||||||
incr css, positions[opp], arrowSize
|
|
||||||
incr arrowCss, positions[pAlign], arrowSize*2 if pAlign in mainPositions
|
|
||||||
|
|
||||||
#calculate container alignment
|
|
||||||
if pMain in vAligns
|
|
||||||
incr css, 'left', realign(pAlign, contW, elemW)
|
|
||||||
incr arrowCss, 'left', realign(pAlign, arrowSize, elemIW) if arrowCss
|
|
||||||
else if pMain in hAligns
|
|
||||||
incr css, 'top', realign(pAlign, contH, elemH)
|
|
||||||
incr arrowCss, 'top', realign(pAlign, arrowSize, elemIH) if arrowCss
|
|
||||||
|
|
||||||
css.display = 'block' if @container.is(":visible")
|
|
||||||
#apply css
|
|
||||||
@container.removeAttr('style').css css
|
|
||||||
@arrow.removeAttr('style').css(arrowCss) if arrowCss
|
|
||||||
|
|
||||||
getPosition: ->
|
|
||||||
|
|
||||||
text = @options.position or if @elem then @options.elementPosition else @options.globalPosition
|
|
||||||
|
|
||||||
pos = parsePosition text
|
|
||||||
|
|
||||||
#validate position
|
|
||||||
pos[0] = 'b' if pos.length is 0
|
|
||||||
if pos[0] not in mainPositions
|
|
||||||
throw "Must be one of [#{mainPositions}]"
|
|
||||||
|
|
||||||
#validate alignment
|
|
||||||
if pos.length is 1 or
|
|
||||||
(pos[0] in vAligns and pos[1] not in hAligns) or
|
|
||||||
(pos[0] in hAligns and pos[1] not in vAligns)
|
|
||||||
pos[1] = if pos[0] in hAligns then 'm' else 'l'
|
|
||||||
|
|
||||||
if pos.length is 2
|
|
||||||
pos[2] = pos[1]
|
|
||||||
|
|
||||||
return pos
|
|
||||||
|
|
||||||
getStyle: (name) ->
|
|
||||||
name = @options.style unless name
|
|
||||||
name = 'default' unless name
|
|
||||||
style = styles[name]
|
|
||||||
throw "Missing style: #{name}"unless style
|
|
||||||
style
|
|
||||||
|
|
||||||
updateClasses: ->
|
|
||||||
classes = ['base']
|
|
||||||
|
|
||||||
if $.isArray @options.className
|
|
||||||
classes = classes.concat @options.className
|
|
||||||
else if @options.className
|
|
||||||
classes.push @options.className
|
|
||||||
|
|
||||||
style = @getStyle()
|
|
||||||
classes = $.map(classes, (n) -> "#{pluginClassName}-#{style.name}-#{n}").join ' '
|
|
||||||
|
|
||||||
@userContainer.attr 'class', classes
|
|
||||||
|
|
||||||
#run plugin
|
|
||||||
run: (data, options) ->
|
|
||||||
#update options
|
|
||||||
if $.isPlainObject(options)
|
|
||||||
$.extend @options, options
|
|
||||||
#shortcut special case
|
|
||||||
else if $.type(options) is 'string'
|
|
||||||
@options.className = options
|
|
||||||
|
|
||||||
if @container and not data
|
|
||||||
@show false
|
|
||||||
return
|
|
||||||
else if not @container and not data
|
|
||||||
return
|
|
||||||
|
|
||||||
datas = {}
|
|
||||||
if $.isPlainObject data
|
|
||||||
datas = data
|
|
||||||
else
|
|
||||||
datas[blankFieldName] = data
|
|
||||||
|
|
||||||
for name, d of datas
|
|
||||||
type = @userFields[name]
|
|
||||||
continue unless type
|
|
||||||
if type is 'text'
|
|
||||||
#escape
|
|
||||||
d = encode(d)
|
|
||||||
d = d.replace(/\n/g,'<br/>') if @options.breakNewLines
|
|
||||||
#update content
|
|
||||||
value = if name is blankFieldName then '' else '='+name
|
|
||||||
find(@userContainer,"[data-notify-#{type}#{value}]").html(d)
|
|
||||||
|
|
||||||
#set styles
|
|
||||||
@updateClasses()
|
|
||||||
|
|
||||||
#positioning
|
|
||||||
if @elem
|
|
||||||
@setElementPosition()
|
|
||||||
else
|
|
||||||
@setGlobalPosition()
|
|
||||||
|
|
||||||
@show true
|
|
||||||
|
|
||||||
#autohide
|
|
||||||
if @options.autoHide
|
|
||||||
clearTimeout @autohideTimer
|
|
||||||
@autohideTimer = setTimeout =>
|
|
||||||
@show false
|
|
||||||
, @options.autoHideDelay
|
|
||||||
|
|
||||||
destroy: ->
|
|
||||||
@wrapper.remove()
|
|
||||||
|
|
||||||
|
|
||||||
# ================================
|
|
||||||
# API
|
|
||||||
# ================================
|
|
||||||
|
|
||||||
# $.pluginName( { ... } ) changes options for all instances
|
|
||||||
$[pluginName] = (elem, data, options) ->
|
|
||||||
if (elem and elem.nodeName) or elem.jquery
|
|
||||||
$(elem)[pluginName](data, options)
|
|
||||||
else
|
|
||||||
options = data
|
|
||||||
data = elem
|
|
||||||
new Notification null, data, options
|
|
||||||
elem
|
|
||||||
|
|
||||||
# $( ... ).pluginName( { .. } ) creates a cached instance on each
|
|
||||||
$.fn[pluginName] = (data, options) ->
|
|
||||||
$(@).each ->
|
|
||||||
inst = getAnchorElement($(@)).data(pluginClassName)
|
|
||||||
if inst
|
|
||||||
inst.run data, options
|
|
||||||
else
|
|
||||||
new Notification $(@), data, options
|
|
||||||
@
|
|
||||||
|
|
||||||
#extra methods
|
|
||||||
$.extend $[pluginName], { defaults, addStyle, pluginOptions, getStyle, insertCSS }
|
|
||||||
|
|
||||||
#when ready
|
|
||||||
$ ->
|
|
||||||
#insert default style
|
|
||||||
insertCSS(coreStyle.css).attr('id', 'core-notify')
|
|
||||||
|
|
||||||
#watch all notifications clicks
|
|
||||||
$(document).on 'click notify-hide', ".#{pluginClassName}-wrapper", (e) ->
|
|
||||||
inst = $(@).data pluginClassName
|
|
||||||
if inst and (inst.options.clickToHide or e.type is 'notify-hide')
|
|
||||||
inst.show false
|
|
||||||
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
* Styles in CoffeeScript go here, which will be compiled into `dist/styles`
|
|
||||||
* Styles in JavaScript can go straight in `dist/styles/`
|
|
||||||
@@ -1,40 +0,0 @@
|
|||||||
|
|
||||||
$.notify.addStyle "bootstrap",
|
|
||||||
html: """
|
|
||||||
<div>
|
|
||||||
<span data-notify-text></span>
|
|
||||||
</div>
|
|
||||||
"""
|
|
||||||
classes:
|
|
||||||
base:
|
|
||||||
"font-weight": "bold"
|
|
||||||
"padding": "8px 15px 8px 14px"
|
|
||||||
"text-shadow": "0 1px 0 rgba(255, 255, 255, 0.5)"
|
|
||||||
"background-color": "#fcf8e3"
|
|
||||||
"border": "1px solid #fbeed5"
|
|
||||||
"border-radius": "4px"
|
|
||||||
"white-space": "nowrap"
|
|
||||||
#for background-image
|
|
||||||
"padding-left": "25px"
|
|
||||||
"background-repeat": "no-repeat"
|
|
||||||
"background-position": "3px 7px"
|
|
||||||
error:
|
|
||||||
"color": "#B94A48"
|
|
||||||
"background-color": "#F2DEDE"
|
|
||||||
"border-color": "#EED3D7"
|
|
||||||
"background-image": "url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAtRJREFUeNqkVc1u00AQHq+dOD+0poIQfkIjalW0SEGqRMuRnHos3DjwAH0ArlyQeANOOSMeAA5VjyBxKBQhgSpVUKKQNGloFdw4cWw2jtfMOna6JOUArDTazXi/b3dm55socPqQhFka++aHBsI8GsopRJERNFlY88FCEk9Yiwf8RhgRyaHFQpPHCDmZG5oX2ui2yilkcTT1AcDsbYC1NMAyOi7zTX2Agx7A9luAl88BauiiQ/cJaZQfIpAlngDcvZZMrl8vFPK5+XktrWlx3/ehZ5r9+t6e+WVnp1pxnNIjgBe4/6dAysQc8dsmHwPcW9C0h3fW1hans1ltwJhy0GxK7XZbUlMp5Ww2eyan6+ft/f2FAqXGK4CvQk5HueFz7D6GOZtIrK+srupdx1GRBBqNBtzc2AiMr7nPplRdKhb1q6q6zjFhrklEFOUutoQ50xcX86ZlqaZpQrfbBdu2R6/G19zX6XSgh6RX5ubyHCM8nqSID6ICrGiZjGYYxojEsiw4PDwMSL5VKsC8Yf4VRYFzMzMaxwjlJSlCyAQ9l0CW44PBADzXhe7xMdi9HtTrdYjFYkDQL0cn4Xdq2/EAE+InCnvADTf2eah4Sx9vExQjkqXT6aAERICMewd/UAp/IeYANM2joxt+q5VI+ieq2i0Wg3l6DNzHwTERPgo1ko7XBXj3vdlsT2F+UuhIhYkp7u7CarkcrFOCtR3H5JiwbAIeImjT/YQKKBtGjRFCU5IUgFRe7fF4cCNVIPMYo3VKqxwjyNAXNepuopyqnld602qVsfRpEkkz+GFL1wPj6ySXBpJtWVa5xlhpcyhBNwpZHmtX8AGgfIExo0ZpzkWVTBGiXCSEaHh62/PoR0p/vHaczxXGnj4bSo+G78lELU80h1uogBwWLf5YlsPmgDEd4M236xjm+8nm4IuE/9u+/PH2JXZfbwz4zw1WbO+SQPpXfwG/BBgAhCNZiSb/pOQAAAAASUVORK5CYII=)"
|
|
||||||
success:
|
|
||||||
"color": "#468847"
|
|
||||||
"background-color": "#DFF0D8"
|
|
||||||
"border-color": "#D6E9C6"
|
|
||||||
"background-image": "url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAutJREFUeNq0lctPE0Ecx38zu/RFS1EryqtgJFA08YCiMZIAQQ4eRG8eDGdPJiYeTIwHTfwPiAcvXIwXLwoXPaDxkWgQ6islKlJLSQWLUraPLTv7Gme32zoF9KSTfLO7v53vZ3d/M7/fIth+IO6INt2jjoA7bjHCJoAlzCRw59YwHYjBnfMPqAKWQYKjGkfCJqAF0xwZjipQtA3MxeSG87VhOOYegVrUCy7UZM9S6TLIdAamySTclZdYhFhRHloGYg7mgZv1Zzztvgud7V1tbQ2twYA34LJmF4p5dXF1KTufnE+SxeJtuCZNsLDCQU0+RyKTF27Unw101l8e6hns3u0PBalORVVVkcaEKBJDgV3+cGM4tKKmI+ohlIGnygKX00rSBfszz/n2uXv81wd6+rt1orsZCHRdr1Imk2F2Kob3hutSxW8thsd8AXNaln9D7CTfA6O+0UgkMuwVvEFFUbbAcrkcTA8+AtOk8E6KiQiDmMFSDqZItAzEVQviRkdDdaFgPp8HSZKAEAL5Qh7Sq2lIJBJwv2scUqkUnKoZgNhcDKhKg5aH+1IkcouCAdFGAQsuWZYhOjwFHQ96oagWgRoUov1T9kRBEODAwxM2QtEUl+Wp+Ln9VRo6BcMw4ErHRYjH4/B26AlQoQQTRdHWwcd9AH57+UAXddvDD37DmrBBV34WfqiXPl61g+vr6xA9zsGeM9gOdsNXkgpEtTwVvwOklXLKm6+/p5ezwk4B+j6droBs2CsGa/gNs6RIxazl4Tc25mpTgw/apPR1LYlNRFAzgsOxkyXYLIM1V8NMwyAkJSctD1eGVKiq5wWjSPdjmeTkiKvVW4f2YPHWl3GAVq6ymcyCTgovM3FzyRiDe2TaKcEKsLpJvNHjZgPNqEtyi6mZIm4SRFyLMUsONSSdkPeFtY1n0mczoY3BHTLhwPRy9/lzcziCw9ACI+yql0VLzcGAZbYSM5CCSZg1/9oc/nn7+i8N9p/8An4JMADxhH+xHfuiKwAAAABJRU5ErkJggg==)"
|
|
||||||
info:
|
|
||||||
"color": "#3A87AD"
|
|
||||||
"background-color": "#D9EDF7"
|
|
||||||
"border-color": "#BCE8F1"
|
|
||||||
"background-image": "url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH3QYFAhkSsdes/QAAA8dJREFUOMvVlGtMW2UYx//POaWHXg6lLaW0ypAtw1UCgbniNOLcVOLmAjHZolOYlxmTGXVZdAnRfXQm+7SoU4mXaOaiZsEpC9FkiQs6Z6bdCnNYruM6KNBw6YWewzl9z+sHImEWv+vz7XmT95f/+3/+7wP814v+efDOV3/SoX3lHAA+6ODeUFfMfjOWMADgdk+eEKz0pF7aQdMAcOKLLjrcVMVX3xdWN29/GhYP7SvnP0cWfS8caSkfHZsPE9Fgnt02JNutQ0QYHB2dDz9/pKX8QjjuO9xUxd/66HdxTeCHZ3rojQObGQBcuNjfplkD3b19Y/6MrimSaKgSMmpGU5WevmE/swa6Oy73tQHA0Rdr2Mmv/6A1n9w9suQ7097Z9lM4FlTgTDrzZTu4StXVfpiI48rVcUDM5cmEksrFnHxfpTtU/3BFQzCQF/2bYVoNbH7zmItbSoMj40JSzmMyX5qDvriA7QdrIIpA+3cdsMpu0nXI8cV0MtKXCPZev+gCEM1S2NHPvWfP/hL+7FSr3+0p5RBEyhEN5JCKYr8XnASMT0xBNyzQGQeI8fjsGD39RMPk7se2bd5ZtTyoFYXftF6y37gx7NeUtJJOTFlAHDZLDuILU3j3+H5oOrD3yWbIztugaAzgnBKJuBLpGfQrS8wO4FZgV+c1IxaLgWVU0tMLEETCos4xMzEIv9cJXQcyagIwigDGwJgOAtHAwAhisQUjy0ORGERiELgG4iakkzo4MYAxcM5hAMi1WWG1yYCJIcMUaBkVRLdGeSU2995TLWzcUAzONJ7J6FBVBYIggMzmFbvdBV44Corg8vjhzC+EJEl8U1kJtgYrhCzgc/vvTwXKSib1paRFVRVORDAJAsw5FuTaJEhWM2SHB3mOAlhkNxwuLzeJsGwqWzf5TFNdKgtY5qHp6ZFf67Y/sAVadCaVY5YACDDb3Oi4NIjLnWMw2QthCBIsVhsUTU9tvXsjeq9+X1d75/KEs4LNOfcdf/+HthMnvwxOD0wmHaXr7ZItn2wuH2SnBzbZAbPJwpPx+VQuzcm7dgRCB57a1uBzUDRL4bfnI0RE0eaXd9W89mpjqHZnUI5Hh2l2dkZZUhOqpi2qSmpOmZ64Tuu9qlz/SEXo6MEHa3wOip46F1n7633eekV8ds8Wxjn37Wl63VVa+ej5oeEZ/82ZBETJjpJ1Rbij2D3Z/1trXUvLsblCK0XfOx0SX2kMsn9dX+d+7Kf6h8o4AIykuffjT8L20LU+w4AZd5VvEPY+XpWqLV327HR7DzXuDnD8r+ovkBehJ8i+y8YAAAAASUVORK5CYII=)"
|
|
||||||
warn:
|
|
||||||
"color": "#C09853"
|
|
||||||
"background-color": "#FCF8E3"
|
|
||||||
"border-color": "#FBEED5"
|
|
||||||
"background-image": "url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAMAAAC6V+0/AAABJlBMVEXr6eb/2oD/wi7/xjr/0mP/ykf/tQD/vBj/3o7/uQ//vyL/twebhgD/4pzX1K3z8e349vK6tHCilCWbiQymn0jGworr6dXQza3HxcKkn1vWvV/5uRfk4dXZ1bD18+/52YebiAmyr5S9mhCzrWq5t6ufjRH54aLs0oS+qD751XqPhAybhwXsujG3sm+Zk0PTwG6Shg+PhhObhwOPgQL4zV2nlyrf27uLfgCPhRHu7OmLgAafkyiWkD3l49ibiAfTs0C+lgCniwD4sgDJxqOilzDWowWFfAH08uebig6qpFHBvH/aw26FfQTQzsvy8OyEfz20r3jAvaKbhgG9q0nc2LbZxXanoUu/u5WSggCtp1anpJKdmFz/zlX/1nGJiYmuq5Dx7+sAAADoPUZSAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxMAAAsTAQCanBgAAAAHdElNRQfdBgUBGhh4aah5AAAAlklEQVQY02NgoBIIE8EUcwn1FkIXM1Tj5dDUQhPU502Mi7XXQxGz5uVIjGOJUUUW81HnYEyMi2HVcUOICQZzMMYmxrEyMylJwgUt5BljWRLjmJm4pI1hYp5SQLGYxDgmLnZOVxuooClIDKgXKMbN5ggV1ACLJcaBxNgcoiGCBiZwdWxOETBDrTyEFey0jYJ4eHjMGWgEAIpRFRCUt08qAAAAAElFTkSuQmCC)"
|
|
||||||
Reference in New Issue
Block a user