delogger 0.3.5 → 0.3.6.final

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 0db19763e3fcae2a39a912413a7d1896873dee9a
4
- data.tar.gz: 8415c8177682bb5df3ee49506de6dde9def29365
3
+ metadata.gz: 18c6f2c276e2f8b823d5d4f61f9a12b4d2247f3c
4
+ data.tar.gz: e66b25896d5e6da26bd720c0d134f878debe5ce3
5
5
  SHA512:
6
- metadata.gz: 7f43d90fdd06b86d61c6352b3b3af698b37936aacc2b1d6607759ed2661a42b207f78f3ed05803a7eb2c21f67f4965f5cc752e0d9a3aada16565caabf10c5a67
7
- data.tar.gz: f407db4d2f6b687c312937f10c4561028e4981daa8e8d3a3ef1ef57200763bd97e51eee9bc041575ffa7433da8b2bfd31b5d6195d70a299ef3c6ac29dcd29b37
6
+ metadata.gz: fab403710641741bbdeb3bed76ecfcde9624aa1465a7d7684a7347d48d9c73f4e956b75c0e624a57e56a7a927b5ade869cebde08839dc60a473d4ebcf930123f
7
+ data.tar.gz: 5dda0ed118fe269029f8191a902708b8ae8cf96ba73d86d9dbc7cdf92dcab3241185057388a76c699cf512c4382b99b3eecc930930e556cd8da5ec5ab0b9bc71
data/README.md CHANGED
@@ -1,5 +1,7 @@
1
1
  [![Gem Version](https://badge.fury.io/rb/delogger.svg)](https://badge.fury.io/rb/delogger)
2
2
 
3
+ # MOVED TO https://github.com/akxcv/crocon !!
4
+
3
5
  # Delogger
4
6
 
5
7
  This gem is a wrapper for browser's `window.console` object. It makes your console convenient and
@@ -1,5 +1,5 @@
1
1
  module Delogger
2
2
  module Rails
3
- VERSION = "0.3.5"
3
+ VERSION = "0.3.6.final"
4
4
  end
5
5
  end
@@ -1 +1 @@
1
- (function(){var t=[].slice;this.Delogger=function(){function r(t){var r,e,o;null==t&&(t={}),o=null==t.enabledByDefault||t.enabledByDefault,e=null==t.enableFormatting||t.enableFormatting,r=null==t.collapseGroups||t.collapseGroups,this.settings={enabledByDefault:o,enableFormatting:e,collapseGroups:r},this.currentGroupStack=[],this.previousGroupStack=[]}var e;return e=["log","info","debug","warn","error","focus"],r.prototype.log=function(){return this.perform.apply(this,["log"].concat(t.call(arguments)))},r.prototype.info=function(){return this.perform.apply(this,["info"].concat(t.call(arguments)))},r.prototype.debug=function(){return this.perform.apply(this,["debug"].concat(t.call(arguments)))},r.prototype.warn=function(){return this.perform.apply(this,["warn"].concat(t.call(arguments)))},r.prototype.error=function(){return this.perform.apply(this,["error"].concat(t.call(arguments)))},r.prototype.assert=function(){return this.perform.apply(this,["assert"].concat(t.call(arguments)))},r.prototype.count=function(){return this.perform.apply(this,["count"].concat(t.call(arguments)))},r.prototype.dir=function(){return this.perform.apply(this,["dir"].concat(t.call(arguments)))},r.prototype.dirxml=function(){return this.perform.apply(this,["dirxml"].concat(t.call(arguments)))},r.prototype.profile=function(){return this.perform.apply(this,["profile"].concat(t.call(arguments)))},r.prototype.time=function(){return this.perform.apply(this,["time"].concat(t.call(arguments)))},r.prototype.timeEnd=function(){return this.perform("timeEnd")},r.prototype.trace=function(){return this.perform.apply(this,["trace"].concat(t.call(arguments)))},r.prototype.enable=function(){return localStorage.setItem("deloggerEnabled",!0)},r.prototype.disable=function(){return localStorage.setItem("deloggerEnabled",!1)},r.prototype.focus=function(){return arguments.length<1?localStorage.setItem("deloggerFocus",!0):this.perform.apply(this,["focus"].concat(t.call(arguments)))},r.prototype.unfocus=function(){return localStorage.removeItem("deloggerFocus")},r.prototype.group=function(){var r,e,o,n,l,a,c,i,u,p,s,f,h,g;if(g=1<=arguments.length?t.call(arguments,0):[],this.canPrint()){for(this.currentGroupStack=g,e=this.settings.collapseGroups?"groupCollapsed":"group",r=0,s=this.previousGroupStack,l=n=0,i=s.length;n<i;l=++n)p=s[l],p===this.currentGroupStack[l]&&(r+=1);if(o=this.previousGroupStack.length-r)for(a=1,f=o;1<=f?a<=f:a>=f;1<=f?a++:a--)console.groupEnd();for(h=this.currentGroupStack.slice(r),c=0,u=h.length;c<u;c++)p=h[c],console[e](p);return this}},r.prototype.perform=function(){var r,o,n,l,a;if(l=arguments[0],r=2<=arguments.length?t.call(arguments,1):[],!this.currentGroupStack.length)for(n=1,a=this.previousGroupStack.length;1<=a?n<=a:n>=a;1<=a?n++:n--)console.groupEnd();this.previousGroupStack=this.currentGroupStack,this.currentGroupStack=[],o=e.indexOf(l)>-1&&this.settings.enableFormatting?this.format.apply(this,[l].concat(t.call(r))):r,this.print.apply(this,[l].concat(t.call(o)))},r.prototype.print=function(){var r,e;if(e=arguments[0],r=2<=arguments.length?t.call(arguments,1):[],this.canPrint(e))return"focus"===e&&(e="log"),console[e].apply(console,r)},r.prototype.enabled=function(){return null!=localStorage.deloggerEnabled?"false"!==localStorage.deloggerEnabled:this.settings.enabledByDefault},r.prototype.canPrint=function(t){return!!this.enabled()&&("focus"===t||null==localStorage.deloggerFocus)},r.prototype.format=function(){var e,o,n,l,a,c,i,u,p,s,f;for(u=arguments[0],o=2<=arguments.length?t.call(arguments,1):[],f="",s=[],l=0,"focus"===u&&(f+="%cfocus%c ",s.push(computeStyle("badge focus")),s.push(computeStyle("default"))),c=0,i=o.length;c<i&&(e=o[c],n=r.Formatter.format(e),null!=n);c++)a=n[0],p=n[1],f+=a,s.push.apply(s,p),l+=1;return o.splice(0,l),[f].concat(t.call(s),t.call(o))},r}(),Delogger.Formatter=function(){function t(){}var r,e,o,n,l,a;return t.format=function(t){if("string"==typeof t)return o(t)},o=function(t){var o,n,a,c;for(c=[];r(t);)n=l(t),a=n.format.replacer||function(t,r){return"%c"+r+"%c"},o="string"==typeof n.format.classes?n.format.classes:n.format.classes(n.match),t=t.replace(n.format.regex,a),c.push(e(o)),c.push(e("default"));return[t,c]},r=function(t){var r,e,o;for(e=0,o=n.length;e<o;e++)if(r=n[e],r.regex.test(t))return!0;return!1},l=function(t){var r,e;return e=function(){var e,o,l;for(l=[],e=0,o=n.length;e<o;e++)r=n[e],r.regex.test(t)&&l.push({match:t.match(r.regex),format:r});return l}(),e.sort(function(t,r){return t.match.index-r.match.index})[0]},e=function(t){var r,e,o,n;return e=document.createElement("div"),e.id="delogger",e.className=t,e.style="display: none;",document.getElementsByTagName("body")[0].appendChild(e),r=getComputedStyle(e),n=function(){var t,e,n;for(n=[],t=0,e=a.length;t<e;t++)o=a[t],n.push(o+":"+r.getPropertyValue(o));return n}().join(";"),e.parentNode.removeChild(e),n},a=["margin","color","background-color","border-radius","padding","font-weight","font-style","text-decoration"],n=[{regex:/\*\*([^\*]+)\*\*/,classes:"bold"},{regex:/\*([^\*]+)\*/,classes:"italic"},{regex:/~([^~]+)~/,classes:"strikethrough"},{regex:/_([^_]+)_/,classes:"underline"},{regex:/\[([^\[\]]+)\](\.[\.\w]+)?(\{[^\{\}]+\})?/,classes:function(t){var r,e,o;return r=t[0],e=t[1],o=t[2],o.split(".").join(" ")}}],t}()}).call(this);
1
+ (function(){var t=[].slice;this.Delogger=function(){function r(t){var r,e,o;null==t&&(t={}),o=null==t.enabledByDefault||t.enabledByDefault,e=null==t.enableFormatting||t.enableFormatting,r=null==t.collapseGroups||t.collapseGroups,this.settings={enabledByDefault:o,enableFormatting:e,collapseGroups:r},this.currentGroupStack=[],this.previousGroupStack=[]}var e;return e=["log","info","debug","warn","error","focus"],r.prototype.log=function(){return this.perform.apply(this,["log"].concat(t.call(arguments)))},r.prototype.info=function(){return this.perform.apply(this,["info"].concat(t.call(arguments)))},r.prototype.debug=function(){return this.perform.apply(this,["debug"].concat(t.call(arguments)))},r.prototype.warn=function(){return this.perform.apply(this,["warn"].concat(t.call(arguments)))},r.prototype.error=function(){return this.perform.apply(this,["error"].concat(t.call(arguments)))},r.prototype.assert=function(){return this.perform.apply(this,["assert"].concat(t.call(arguments)))},r.prototype.count=function(){return this.perform.apply(this,["count"].concat(t.call(arguments)))},r.prototype.dir=function(){return this.perform.apply(this,["dir"].concat(t.call(arguments)))},r.prototype.dirxml=function(){return this.perform.apply(this,["dirxml"].concat(t.call(arguments)))},r.prototype.profile=function(){return this.perform.apply(this,["profile"].concat(t.call(arguments)))},r.prototype.time=function(){return this.perform.apply(this,["time"].concat(t.call(arguments)))},r.prototype.timeEnd=function(){return this.perform("timeEnd")},r.prototype.trace=function(){return this.perform.apply(this,["trace"].concat(t.call(arguments)))},r.prototype.enable=function(){return localStorage.setItem("deloggerEnabled",!0)},r.prototype.disable=function(){return localStorage.setItem("deloggerEnabled",!1)},r.prototype.focus=function(){return arguments.length<1?localStorage.setItem("deloggerFocus",!0):this.perform.apply(this,["focus"].concat(t.call(arguments)))},r.prototype.unfocus=function(){return localStorage.removeItem("deloggerFocus")},r.prototype.group=function(){var r,e,o,n,l,a,c,i,u,p,s,f,h,g;if(g=1<=arguments.length?t.call(arguments,0):[],!this.canPrint())return this;for(this.currentGroupStack=g,e=this.settings.collapseGroups?"groupCollapsed":"group",r=0,s=this.previousGroupStack,l=n=0,i=s.length;n<i;l=++n)p=s[l],p===this.currentGroupStack[l]&&(r+=1);if(o=this.previousGroupStack.length-r)for(a=1,f=o;1<=f?a<=f:a>=f;1<=f?a++:a--)console.groupEnd();for(h=this.currentGroupStack.slice(r),c=0,u=h.length;c<u;c++)p=h[c],console[e](p);return this},r.prototype.perform=function(){var r,o,n,l,a;if(l=arguments[0],r=2<=arguments.length?t.call(arguments,1):[],!this.currentGroupStack.length)for(n=1,a=this.previousGroupStack.length;1<=a?n<=a:n>=a;1<=a?n++:n--)console.groupEnd();this.previousGroupStack=this.currentGroupStack,this.currentGroupStack=[],o=e.indexOf(l)>-1&&this.settings.enableFormatting?this.format.apply(this,[l].concat(t.call(r))):r,this.print.apply(this,[l].concat(t.call(o)))},r.prototype.print=function(){var r,e;if(e=arguments[0],r=2<=arguments.length?t.call(arguments,1):[],this.canPrint(e))return"focus"===e&&(e="log"),console[e].apply(console,r)},r.prototype.enabled=function(){return null!=localStorage.deloggerEnabled?"false"!==localStorage.deloggerEnabled:this.settings.enabledByDefault},r.prototype.canPrint=function(t){return!!this.enabled()&&("focus"===t||null==localStorage.deloggerFocus)},r.prototype.format=function(){var e,o,n,l,a,c,i,u,p,s,f;for(u=arguments[0],o=2<=arguments.length?t.call(arguments,1):[],f="",s=[],l=0,"focus"===u&&(f+="%cfocus%c ",s.push(computeStyle("badge focus")),s.push(computeStyle("default"))),c=0,i=o.length;c<i&&(e=o[c],n=r.Formatter.format(e),null!=n);c++)a=n[0],p=n[1],f+=a,s.push.apply(s,p),l+=1;return o.splice(0,l),[f].concat(t.call(s),t.call(o))},r}(),Delogger.Formatter=function(){function t(){}var r,e,o,n,l,a;return t.format=function(t){if("string"==typeof t)return o(t)},o=function(t){var o,n,a,c;for(c=[];r(t);)n=l(t),a=n.format.replacer||function(t,r){return"%c"+r+"%c"},o="string"==typeof n.format.classes?n.format.classes:n.format.classes(n.match),t=t.replace(n.format.regex,a),c.push(e(o)),c.push(e("default"));return[t,c]},r=function(t){var r,e,o;for(e=0,o=n.length;e<o;e++)if(r=n[e],r.regex.test(t))return!0;return!1},l=function(t){var r,e;return e=function(){var e,o,l;for(l=[],e=0,o=n.length;e<o;e++)r=n[e],r.regex.test(t)&&l.push({match:t.match(r.regex),format:r});return l}(),e.sort(function(t,r){return t.match.index-r.match.index})[0]},e=function(t){var r,e,o,n;return e=document.createElement("div"),e.id="delogger",e.className=t,e.style="display: none;",document.getElementsByTagName("body")[0].appendChild(e),r=getComputedStyle(e),n=function(){var t,e,n;for(n=[],t=0,e=a.length;t<e;t++)o=a[t],n.push(o+":"+r.getPropertyValue(o));return n}().join(";"),e.parentNode.removeChild(e),n},a=["margin","color","background-color","border-radius","padding","font-weight","font-style","text-decoration"],n=[{regex:/\*\*([^\*]+)\*\*/,classes:"bold"},{regex:/\*([^\*]+)\*/,classes:"italic"},{regex:/~([^~]+)~/,classes:"strikethrough"},{regex:/_([^_]+)_/,classes:"underline"},{regex:/\[([^\[\]]+)\](\.[\.\w]+)?(\{[^\{\}]+\})?/,classes:function(t){var r,e,o;return r=t[0],e=t[1],o=t[2],o.split(".").join(" ")}}],t}()}).call(this);
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: delogger
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.5
4
+ version: 0.3.6.final
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexander Komarov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-02-08 00:00:00.000000000 Z
11
+ date: 2017-02-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -81,7 +81,7 @@ dependencies:
81
81
  - !ruby/object:Gem::Version
82
82
  version: '0'
83
83
  description: |-
84
- Turn your console on and off globally or locally.
84
+ This gem is moved to https://github.com/akxcv/crocon-rails !! Turn your console on and off globally or locally.
85
85
  Format your output with colors and badges.
86
86
  email:
87
87
  - ak@akxcv.com
@@ -106,7 +106,8 @@ homepage: https://github.com/akxcv/delogger
106
106
  licenses:
107
107
  - MIT
108
108
  metadata: {}
109
- post_install_message:
109
+ post_install_message: This gem is moved to https://github.com/akxcv/crocon-rails !!
110
+ The version you're using right now is no longer supported!
110
111
  rdoc_options: []
111
112
  require_paths:
112
113
  - lib
@@ -117,9 +118,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
117
118
  version: '0'
118
119
  required_rubygems_version: !ruby/object:Gem::Requirement
119
120
  requirements:
120
- - - ">="
121
+ - - ">"
121
122
  - !ruby/object:Gem::Version
122
- version: '0'
123
+ version: 1.3.1
123
124
  requirements: []
124
125
  rubyforge_project:
125
126
  rubygems_version: 2.6.8