cani 0.5.1 → 0.5.2

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
  SHA256:
3
- metadata.gz: d821ab62236b32025cd182c4c0196d1d8a4a707ea9a4308ef93347baba029c30
4
- data.tar.gz: d12c12cb0bb5f6e91a40b7d9525642a5b5f4e78c7980b481ef03294061504b14
3
+ metadata.gz: 8b3bfdea3cdcd9f53dad3c04993ab289f935053ea36a5facb58f4c4a8c7bc66b
4
+ data.tar.gz: 35a9526b42ac5e4ac3d1cc31dd0a8da559a26ed282ff7f9205d12fd30559b245
5
5
  SHA512:
6
- metadata.gz: edab77a93d813b073ebb9acc9de3b130a5f8f4768f94b4ebb85c58f2efa2313fda1a22c0aaf15c9d73ab2d0bc4de01a38fe57402c11836729795baa5434b64f1
7
- data.tar.gz: c246b07a7a08d79e42c76c632c48286c32d9bfe5907da3360f93ed42888ee405def686fc4ece30ff00d04e2f0d8aaa56d04d752faf2a7ad2c9bbd23cdbbba613
6
+ metadata.gz: 19fbf82938be788b4779bed524134b72a7ce65026f558bb239252896dcd7fac58539499ee87335b9926c35d17f4678f72a8190837ae394f2bd3ffb4acaec92b1
7
+ data.tar.gz: 4e1b54b2e74637b8ea14329f43b40bf7d67cf7482d503231edd04733176b00788a3434c4869081e0998951eb969a68e1acaf2e6c347cea33ade86016bbf1a10a
data/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # Cani — a [caniuse.com](caniuse.com) tui interface
1
+ # Cani — a [caniuse.com](caniuse.com) tui interface ![Licence](https://img.shields.io/badge/license-MIT-E9573F.svg) [![Gem Version](https://img.shields.io/gem/v/cani.svg?colorB=E9573F&style=square)](rubygems.org/gems/cani) [![Issues](https://img.shields.io/github/issues/SidOfc/cani.svg)](https://github.com/SidOfc/cani/issues)
2
2
 
3
3
  ![cani cli](/assets/cani.png)
4
4
 
data/lib/cani.rb CHANGED
@@ -55,8 +55,8 @@ module Cani
55
55
  puts 'cani is dependent on fzf (https://github.com/junegunn/fzf) for the interactive TUI to work.'.light_black
56
56
  puts 'without fzf, commands can still be piped to get the regular (colorless) output'.light_black
57
57
  puts ''
58
- puts 'Cani requires at least 20 lines and 40 cols to work properly, this is not a hard limit but'
59
- puts 'below this width, long lines could wrap a lot and reduce visible information.'
58
+ puts 'Cani requires at least 20 lines and 40 cols to work properly, this is not a hard limit but'.light_black
59
+ puts 'below this width, long lines could wrap a lot and reduce visible information.'.light_black
60
60
  puts ''
61
61
  puts 'Usage:'.red
62
62
  puts ' cani'.yellow + ' [COMMAND [ARGUMENTS]]'
@@ -207,6 +207,7 @@ module Cani
207
207
  note_nums = feature.browser_note_nums.fetch(browser.name, {})
208
208
  .fetch(era, [])
209
209
 
210
+ # do not draw era's that exceed screen height
210
211
  break if (ey + (is_current ? 1 : bot_pad) + 1) >= height
211
212
 
212
213
  if do_draw && is_current
@@ -218,7 +219,7 @@ module Cani
218
219
  end
219
220
 
220
221
  # only show visible / relevant browsers
221
- if browser.usage[era].to_i >= 0.5 || (!era.empty? && cur_era >= era_idx)
222
+ if browser.usage[era].to_i >= 0.5 || (!era.empty? && cur_era >= era_idx - 1)
222
223
  if do_draw
223
224
  ((ey - top_pad)..(ey + (is_current ? 1 : bot_pad))).each do |ry|
224
225
  txt = (bot_pad.zero? && !is_current) ? (ry >= ey + (is_current ? 1 : bot_pad) ? era.to_s : ' ')
data/lib/cani/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Cani
2
- VERSION = "0.5.1"
2
+ VERSION = "0.5.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cani
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1
4
+ version: 0.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sidney Liebrand
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-07-28 00:00:00.000000000 Z
11
+ date: 2018-09-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: colorize