ui_bibz 2.3.5 → 2.3.6

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: 78102df53c7b5ad064601113682ad48c22355bf38735876338b8eefc3a11c642
4
- data.tar.gz: 49b6a64b79bff1022b00aaf23a4803b935d877259893ca8b7df5b8ef066e2df7
3
+ metadata.gz: b3a05f2192bfbfe9c05a250aa2957e546d94057dc57c7af3853ea466644b0e9e
4
+ data.tar.gz: b40362d959e08bffa4a5e8b49f6fcb27dbc9f9da5eb0948513532f5a475a5b04
5
5
  SHA512:
6
- metadata.gz: 8ac55be2e5208d5c874f5356da8f068c0826ede56758c4d18c610ce516cd747b29ac4244813e420d75be92afb83426d1a335fb6f0cd67926018f35e78247b4e7
7
- data.tar.gz: ac6b1652b6e97ba57f4d55da602d158b85c0b0294705449ca29b3b8a7e22cb4f793659c79124d85b39891e068ff01c0173f5bcfbb2c726a949a574bf813c06d0
6
+ metadata.gz: 6d63248786dcaf8e956db8d0bb88b2e90a5198ad2e7dd18fda9fb680aa4bf6d6dac373e6f0dc2145fb95ba02f8391603aa676624f6c0080cefe32ad42d3a5f9c
7
+ data.tar.gz: 21e3af3c7b02b8c730439ee40d644c10832f41f76f9e390464c3066c7c9ab878406d64b65a9e577249e20fccd958a16eada21b94e32d768e70d7e01a83ae1999
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- ui_bibz (2.3.5)
4
+ ui_bibz (2.3.6)
5
5
  bootstrap (= 4.3.1)
6
6
  haml
7
7
  haml-rails
@@ -16,49 +16,49 @@ PATH
16
16
  GEM
17
17
  remote: https://rubygems.org/
18
18
  specs:
19
- actioncable (5.2.2.1)
20
- actionpack (= 5.2.2.1)
19
+ actioncable (5.2.3)
20
+ actionpack (= 5.2.3)
21
21
  nio4r (~> 2.0)
22
22
  websocket-driver (>= 0.6.1)
23
- actionmailer (5.2.2.1)
24
- actionpack (= 5.2.2.1)
25
- actionview (= 5.2.2.1)
26
- activejob (= 5.2.2.1)
23
+ actionmailer (5.2.3)
24
+ actionpack (= 5.2.3)
25
+ actionview (= 5.2.3)
26
+ activejob (= 5.2.3)
27
27
  mail (~> 2.5, >= 2.5.4)
28
28
  rails-dom-testing (~> 2.0)
29
- actionpack (5.2.2.1)
30
- actionview (= 5.2.2.1)
31
- activesupport (= 5.2.2.1)
29
+ actionpack (5.2.3)
30
+ actionview (= 5.2.3)
31
+ activesupport (= 5.2.3)
32
32
  rack (~> 2.0)
33
33
  rack-test (>= 0.6.3)
34
34
  rails-dom-testing (~> 2.0)
35
35
  rails-html-sanitizer (~> 1.0, >= 1.0.2)
36
- actionview (5.2.2.1)
37
- activesupport (= 5.2.2.1)
36
+ actionview (5.2.3)
37
+ activesupport (= 5.2.3)
38
38
  builder (~> 3.1)
39
39
  erubi (~> 1.4)
40
40
  rails-dom-testing (~> 2.0)
41
41
  rails-html-sanitizer (~> 1.0, >= 1.0.3)
42
- activejob (5.2.2.1)
43
- activesupport (= 5.2.2.1)
42
+ activejob (5.2.3)
43
+ activesupport (= 5.2.3)
44
44
  globalid (>= 0.3.6)
45
- activemodel (5.2.2.1)
46
- activesupport (= 5.2.2.1)
47
- activerecord (5.2.2.1)
48
- activemodel (= 5.2.2.1)
49
- activesupport (= 5.2.2.1)
45
+ activemodel (5.2.3)
46
+ activesupport (= 5.2.3)
47
+ activerecord (5.2.3)
48
+ activemodel (= 5.2.3)
49
+ activesupport (= 5.2.3)
50
50
  arel (>= 9.0)
51
- activestorage (5.2.2.1)
52
- actionpack (= 5.2.2.1)
53
- activerecord (= 5.2.2.1)
51
+ activestorage (5.2.3)
52
+ actionpack (= 5.2.3)
53
+ activerecord (= 5.2.3)
54
54
  marcel (~> 0.3.1)
55
- activesupport (5.2.2.1)
55
+ activesupport (5.2.3)
56
56
  concurrent-ruby (~> 1.0, >= 1.0.2)
57
57
  i18n (>= 0.7, < 2)
58
58
  minitest (~> 5.1)
59
59
  tzinfo (~> 1.1)
60
60
  arel (9.0.0)
61
- autoprefixer-rails (9.4.10.2)
61
+ autoprefixer-rails (9.5.1)
62
62
  execjs
63
63
  awesome_print (1.8.0)
64
64
  bootstrap (4.3.1)
@@ -66,7 +66,7 @@ GEM
66
66
  popper_js (>= 1.14.3, < 2)
67
67
  sassc-rails (>= 2.0.0)
68
68
  builder (3.2.3)
69
- byebug (11.0.0)
69
+ byebug (11.0.1)
70
70
  codeclimate-test-reporter (1.0.7)
71
71
  simplecov
72
72
  concurrent-ruby (1.1.5)
@@ -117,33 +117,33 @@ GEM
117
117
  mini_portile2 (2.4.0)
118
118
  minitest (5.11.3)
119
119
  nio4r (2.3.1)
120
- nokogiri (1.10.1)
120
+ nokogiri (1.10.2)
121
121
  mini_portile2 (~> 2.4.0)
122
122
  popper_js (1.14.5)
123
- rack (2.0.6)
123
+ rack (2.0.7)
124
124
  rack-test (1.1.0)
125
125
  rack (>= 1.0, < 3)
126
- rails (5.2.2.1)
127
- actioncable (= 5.2.2.1)
128
- actionmailer (= 5.2.2.1)
129
- actionpack (= 5.2.2.1)
130
- actionview (= 5.2.2.1)
131
- activejob (= 5.2.2.1)
132
- activemodel (= 5.2.2.1)
133
- activerecord (= 5.2.2.1)
134
- activestorage (= 5.2.2.1)
135
- activesupport (= 5.2.2.1)
126
+ rails (5.2.3)
127
+ actioncable (= 5.2.3)
128
+ actionmailer (= 5.2.3)
129
+ actionpack (= 5.2.3)
130
+ actionview (= 5.2.3)
131
+ activejob (= 5.2.3)
132
+ activemodel (= 5.2.3)
133
+ activerecord (= 5.2.3)
134
+ activestorage (= 5.2.3)
135
+ activesupport (= 5.2.3)
136
136
  bundler (>= 1.3.0)
137
- railties (= 5.2.2.1)
137
+ railties (= 5.2.3)
138
138
  sprockets-rails (>= 2.0.0)
139
139
  rails-dom-testing (2.0.3)
140
140
  activesupport (>= 4.2.0)
141
141
  nokogiri (>= 1.6)
142
142
  rails-html-sanitizer (1.0.4)
143
143
  loofah (~> 2.2, >= 2.2.2)
144
- railties (5.2.2.1)
145
- actionpack (= 5.2.2.1)
146
- activesupport (= 5.2.2.1)
144
+ railties (5.2.3)
145
+ actionpack (= 5.2.3)
146
+ activesupport (= 5.2.3)
147
147
  method_source
148
148
  rake (>= 0.8.7)
149
149
  thor (>= 0.19.0, < 2.0)
@@ -151,9 +151,9 @@ GEM
151
151
  rb-fsevent (0.10.3)
152
152
  rb-inotify (0.10.0)
153
153
  ffi (~> 1.0)
154
- ruby_parser (3.13.0)
154
+ ruby_parser (3.13.1)
155
155
  sexp_processor (~> 4.9)
156
- sass (3.7.3)
156
+ sass (3.7.4)
157
157
  sass-listen (~> 4.0.0)
158
158
  sass-listen (4.0.0)
159
159
  rb-fsevent (~> 0.9, >= 0.9.4)
@@ -200,7 +200,7 @@ GEM
200
200
  websocket-extensions (>= 0.1.0)
201
201
  websocket-extensions (0.1.3)
202
202
  will-paginate-i18n (0.1.15)
203
- will_paginate (3.1.6)
203
+ will_paginate (3.1.7)
204
204
  will_paginate-bootstrap4 (0.2.2)
205
205
  will_paginate (~> 3.0, >= 3.0.0)
206
206
 
@@ -9,7 +9,6 @@
9
9
  @notify()
10
10
  @fileInputBrowser()
11
11
  @toast()
12
- @collapse()
13
12
 
14
13
  nav: ->
15
14
  #$('.nav-tabs .nav-item .nav-link').tab('show')
@@ -54,5 +53,3 @@
54
53
  toast: ->
55
54
  $('.toast').toast()
56
55
 
57
- collapse: ->
58
- $('.collapse').collapse()
@@ -10,7 +10,7 @@
10
10
  .progress-bar-line
11
11
  height: 1px
12
12
 
13
- .nav-link
13
+ .nav-tabs .nav-link
14
14
  cursor: pointer
15
15
 
16
16
  .btn-toolbar form
@@ -29,7 +29,7 @@
29
29
  .far,
30
30
  .fal,
31
31
  .fab
32
- line-height: 0.7 !important
32
+ line-height: 0 !important
33
33
 
34
34
  span:not(.input-group-addon, .btn) svg
35
35
  margin-top: -0.1rem
data/lib/ui_bibz/infos.rb CHANGED
@@ -1,6 +1,6 @@
1
1
  module UiBibz
2
2
  NAME = "Ui Bibz"
3
- VERSION = "2.3.5"
3
+ VERSION = "2.3.6"
4
4
  DESCRIPTION = "A Rails Interface Framework using Bootstrap."
5
5
  SUMMARY = "Create your project with Ui Bibz. Over a thirty reusable components built to provide iconography, dropdowns, input groups, navigation, alerts, and much more."
6
6
  LICENSE = "MIT"
@@ -55,7 +55,9 @@ module UiBibzInputs
55
55
  end
56
56
 
57
57
  def input_attribute_name
58
- "#{ @builder.object.class.name.gsub('::', "").underscore }[#{ attribute_name }]"
58
+ new_attribute_name = "#{ @builder.lookup_model_names.first }"
59
+ new_attribute_name += "[#{ @builder.lookup_model_names.second }_attributes]" if @builder.lookup_model_names.second
60
+ new_attribute_name += "[#{ attribute_name }]"
59
61
  end
60
62
 
61
63
  def collection
@@ -21,6 +21,8 @@ module UiBibz::Ui::Core::Forms::Buttons
21
21
  # * +outline+ - Boolean
22
22
  # * +state+ - Symbol (+:active+, +:disabled)
23
23
  # * +type+ - Symbol (+:outline)
24
+ # * +collapse+ - String
25
+ # * +expand_collaspe+ - Boolean
24
26
  # * +glyph+ - Add glyph with name or hash options
25
27
  # * +name+ - String
26
28
  # * +size+ - Integer
@@ -51,11 +53,6 @@ module UiBibz::Ui::Core::Forms::Buttons
51
53
  # end
52
54
  class Button < UiBibz::Ui::Core::Component
53
55
 
54
- # See UiBibz::Ui::Core::Component.initialize
55
- def initialize content = nil, options = nil, html_options = nil, &block
56
- super
57
- end
58
-
59
56
  # Render html tag
60
57
  def pre_render
61
58
  button_html_tag
@@ -85,9 +82,13 @@ module UiBibz::Ui::Core::Forms::Buttons
85
82
  end
86
83
 
87
84
  def collapse
88
- attrs = { "data-toggle": "collapse", "data-target": "##{ options[:collapse] }" }
89
- attrs = attrs.merge({ "aria-expanded": true }) if options[:active_collapse]
90
- attrs
85
+ # Must be flat hash not deep hash
86
+ {
87
+ "data-toggle": :collapse,
88
+ "data-target": "##{ options[:collapse] }",
89
+ "aria-controls": options[:collapse],
90
+ "aria-expanded": options[:expand_collapse].nil? ? false : options[:expand_collapse]
91
+ }
91
92
  end
92
93
 
93
94
  def status
@@ -53,11 +53,6 @@ module UiBibz::Ui::Core::Forms::Buttons
53
53
  #
54
54
  class ButtonLink < UiBibz::Ui::Core::Forms::Buttons::Button
55
55
 
56
- # See UiBibz::Ui::Core::Forms::Buttons::Button
57
- def initialize content = nil, options = nil, html_options = nil, &block
58
- super
59
- end
60
-
61
56
  # Render html tag
62
57
  def pre_render
63
58
  button_link_html_tag
@@ -65,25 +60,29 @@ module UiBibz::Ui::Core::Forms::Buttons
65
60
 
66
61
  private
67
62
 
68
- def component_html_options
69
- opts = super
70
- opts = opts.merge({ role: "button" })
71
- opts
72
- end
73
-
74
63
  def button_link_html_tag
75
64
  link_to link_url, html_options do
76
- concat glyph_and_content_html
65
+ concat spinner_html unless options[:spinner].nil?
66
+ concat glyph_and_content_html(options[:text].nil? ? @content : '')
77
67
  concat badge_html unless options[:badge].nil?
78
68
  end
79
69
  end
80
70
 
81
71
  def link_url
82
- options[:url] || "#"
72
+ options[:url] || "##{ options[:collapse] }"
73
+ end
74
+
75
+ def component_html_options
76
+ super.merge({ role: :button })
83
77
  end
84
78
 
85
- def status
86
- ["btn", outline, options[:status] || :secondary].compact.join('-')
79
+ def collapse
80
+ # Must be flat hash not deep hash
81
+ {
82
+ "data-toggle": :collapse,
83
+ "aria-controls": options[:collapse],
84
+ "aria-expanded": options[:expand_collaspe].nil? ? false : options[:expand_collaspe]
85
+ }
87
86
  end
88
87
 
89
88
  end
@@ -23,7 +23,11 @@ module UiBibz::Ui::Core::Navigations
23
23
 
24
24
  # Render html tag
25
25
  def pre_render
26
- link_to content, brand_url, html_options
26
+ if options[:url]
27
+ link_to content, brand_url, html_options
28
+ else
29
+ content_tag :span, content, html_options
30
+ end
27
31
  end
28
32
 
29
33
  private
@@ -47,7 +47,7 @@ module UiBibz::Ui::Core::Navigations
47
47
 
48
48
  # Render html tag
49
49
  def pre_render
50
- link_to glyph_and_content_html, options[:url] || '#', html_options
50
+ link_to glyph_and_content_html, options[:url] || "##{ options[:collapse] }", html_options
51
51
  end
52
52
 
53
53
  private
@@ -58,10 +58,15 @@ module UiBibz::Ui::Core::Navigations
58
58
  opts
59
59
  end
60
60
 
61
- def collapse
62
- attrs = { role: "button", "data-toggle": "collapse", "data-target": "##{ options[:collapse] }" }
63
- attrs = attrs.merge({ "aria-expanded": true }) if options[:active_collapse]
64
- attrs
61
+ def collapse
62
+ {
63
+ role: "button",
64
+ data: { toggle: :collapse },
65
+ aria: {
66
+ controls: options[:collapse],
67
+ expanded: options[:active_collapse].nil? ? false : options[:active_collapse]
68
+ }
69
+ }
65
70
  end
66
71
 
67
72
  def text
@@ -134,7 +134,7 @@ module UiBibz::Ui::Core::Navigations
134
134
  end
135
135
 
136
136
  def body_html
137
- content_tag :div, class: "collapse navbar-collapse", id: id do
137
+ content_tag :div, class: "navbar-collapse", id: id do
138
138
  concat @items.map(&:render).join.html_safe
139
139
  end
140
140
  end
@@ -18,11 +18,15 @@ module PopoverExtension
18
18
  end
19
19
 
20
20
  def tooltip_data_html
21
- add_html_data :toggle, "tooltip" unless options[:tooltip].nil?
21
+ unless options[:tooltip].nil?
22
+ add_html_data :toggle, "tooltip"
22
23
 
23
- if options[:tooltip].kind_of?(Hash)
24
- TOOLTIP_METHODS.each{ |mth| add_html_data(mth, options[:tooltip].try(:[], mth)) unless options[:tooltip].try(:[], mth).nil? }
25
- add_html_data :placement, options[:tooltip].try(:[], :position) unless options[:tooltip].try(:[], :position).nil?
24
+ if options[:tooltip].kind_of?(Hash)
25
+ TOOLTIP_METHODS.each{ |mth| add_html_data(mth, options[:tooltip].try(:[], mth)) unless options[:tooltip].try(:[], mth).nil? }
26
+ add_html_data :placement, options[:tooltip].try(:[], :position) unless options[:tooltip].try(:[], :position).nil?
27
+ else
28
+ add_html_data :title, options[:tooltip]
29
+ end
26
30
  end
27
31
  end
28
32
 
@@ -23,7 +23,7 @@ module UiBibz::Utils
23
23
  glyph_name = @glyph_options.try(:[], :name)
24
24
  glyph_opts = @glyph_options
25
25
  glyph_html_opts = @options[:html_options] || {}
26
- glyph_html_opts = glyph_html_opts.merge(@options[:text] ? {} : { title: @options[:content] })
26
+ #glyph_html_opts = glyph_html_opts.merge(@options[:text] ? {} : { title: @options[:content] })
27
27
  glyph_items = @glyph_options.try(:[], :items) || []
28
28
 
29
29
  [glyph_name, glyph_opts, glyph_html_opts, glyph_items]
@@ -35,9 +35,9 @@ module UiBibz::Utils
35
35
  else
36
36
  glyph_name = @glyph_options
37
37
  glyph_opts = @options
38
- title = [(@options[:content] unless @options[:text]), ("<kbd>#{ @options[:shortcut] }</kbd>" unless @options[:shortcut].nil?)].compact.join(" ")
38
+ #title = [(@options[:content] unless @options[:text]), ("<kbd>#{ @options[:shortcut] }</kbd>" unless @options[:shortcut].nil?)].compact.join(" ")
39
39
  glyph_html_opts = @options[:html_options] || {}
40
- glyph_html_opts = glyph_html_opts.merge(title.blank? ? {} : { title: title.html_safe })
40
+ # glyph_html_opts = glyph_html_opts.merge(title.blank? ? {} : { title: title.html_safe })
41
41
  end
42
42
 
43
43
  UiBibz::Ui::Core::Icons::Glyph.new(glyph_name, glyph_opts, glyph_html_opts).render unless glyph_name.nil?
@@ -20,7 +20,7 @@ class ComponentTest < ActionView::TestCase
20
20
 
21
21
  test 'create component without text and glyph' do
22
22
  actual = UiBibz::Ui::Core::Component.new('My text', { glyph: 'diamond', text: false }).render
23
- expected = "<i title=\"My text\" class=\"glyph fas fa-diamond\"></i>"
23
+ expected = "<i class=\"glyph fas fa-diamond\"></i>"
24
24
 
25
25
  assert_equal expected, actual
26
26
  end
@@ -75,14 +75,14 @@ class ButtonTest < ActionView::TestCase
75
75
 
76
76
  test 'button glyph without text' do
77
77
  actual = ui_button('state', glyph: 'diamond', text: false)
78
- expected = "<button class=\"btn-secondary btn without-text\"><i title=\"state\" class=\"glyph fas fa-diamond\"></i></button>"
78
+ expected = "<button class=\"btn-secondary btn without-text\"><i class=\"glyph fas fa-diamond\"></i></button>"
79
79
 
80
80
  assert_equal expected, actual
81
81
  end
82
82
 
83
83
  test 'button with collapse' do
84
84
  actual = ui_button('state', collapse: 'collapse-id')
85
- expected = "<button class=\"btn-secondary btn\" data-toggle=\"collapse\" data-target=\"#collapse-id\">state</button>"
85
+ expected = "<button class=\"btn-secondary btn\" data-toggle=\"collapse\" data-target=\"#collapse-id\" aria-controls=\"collapse-id\" aria-expanded=\"false\">state</button>"
86
86
 
87
87
  assert_equal expected, actual
88
88
  end
@@ -102,8 +102,8 @@ class ButtonTest < ActionView::TestCase
102
102
  end
103
103
 
104
104
  test "button with simple tooltip" do
105
- actual = ui_button('My Button', { tooltip: true }, { title: 'My tooltip' })
106
- expected = "<button title=\"My tooltip\" data-toggle=\"tooltip\" class=\"btn-secondary btn\">My Button</button>"
105
+ actual = ui_button('My Button', { tooltip: "My Button" }, { title: 'My tooltip' })
106
+ expected = "<button title=\"My tooltip\" data-toggle=\"tooltip\" data-title=\"My Button\" class=\"btn-secondary btn\">My Button</button>"
107
107
 
108
108
  assert_equal expected, actual
109
109
  end
@@ -11,14 +11,14 @@ class LinkTest < ActionView::TestCase
11
11
 
12
12
  test 'Link without text' do
13
13
  actual = ui_link 'My link', glyph: "gem", text: false, url: "#link"
14
- expected = "<a href=\"#link\"><i title=\"My link\" class=\"glyph fas fa-gem\"></i></a>"
14
+ expected = "<a href=\"#link\"><i class=\"glyph fas fa-gem\"></i></a>"
15
15
 
16
16
  assert_equal expected, actual
17
17
  end
18
18
 
19
19
  test "Link with collapse option" do
20
20
  actual = ui_link 'My link', url: "#link", collapse: 'collapse-id'
21
- expected = "<a role=\"button\" data-toggle=\"collapse\" data-target=\"#collapse-id\" href=\"#link\">My link</a>"
21
+ expected = "<a role=\"button\" data-toggle=\"collapse\" aria-controls=\"collapse-id\" aria-expanded=\"false\" href=\"#link\">My link</a>"
22
22
 
23
23
  assert_equal expected, actual
24
24
  end
@@ -4,7 +4,7 @@ class NavbarTest < ActionView::TestCase
4
4
  test 'Navbar' do
5
5
  actual = UiBibz::Ui::Core::Navigations::Navbar.new.tap do |nb|
6
6
  end
7
- expected = "<nav class=\"navbar navbar-light navbar-expand-lg\"><button class=\"navbar-toggler hidden-sm-up\" type=\"button\" data-toggle=\"collapse\" data-target=\"##{ actual.id }\">☰</button><div class=\"collapse navbar-collapse\" id=\"#{ actual.id }\"></div></nav>"
7
+ expected = "<nav class=\"navbar navbar-light navbar-expand-lg\"><button class=\"navbar-toggler hidden-sm-up\" type=\"button\" data-toggle=\"collapse\" data-target=\"##{ actual.id }\">☰</button><div class=\"navbar-collapse\" id=\"#{ actual.id }\"></div></nav>"
8
8
 
9
9
  assert_equal expected, actual.render
10
10
  end
@@ -12,7 +12,7 @@ class NavbarTest < ActionView::TestCase
12
12
  test 'Navbar with options' do
13
13
  actual = UiBibz::Ui::Core::Navigations::Navbar.new(title: 'Brand', expand_size: :xs, status: :primary, position: :top, brand_position: :right).tap do |nb|
14
14
  end
15
- expected = "<nav class=\"bg-primary navbar navbar-light fixed-top navbar-expand-xs\"><button class=\"navbar-toggler hidden-sm-up\" type=\"button\" data-toggle=\"collapse\" data-target=\"##{ actual.id }\">☰</button><a class=\"navbar-brand\" href=\"/\">Brand</a><div class=\"collapse navbar-collapse\" id=\"#{ actual.id }\"></div></nav>"
15
+ expected = "<nav class=\"bg-primary navbar navbar-light fixed-top navbar-expand-xs\"><button class=\"navbar-toggler hidden-sm-up\" type=\"button\" data-toggle=\"collapse\" data-target=\"##{ actual.id }\">☰</button><span class=\"navbar-brand\">Brand</span><div class=\"navbar-collapse\" id=\"#{ actual.id }\"></div></nav>"
16
16
 
17
17
  assert_equal expected, actual.render
18
18
  end
@@ -31,7 +31,7 @@ class NavbarTest < ActionView::TestCase
31
31
  end
32
32
  nb.text 'test'
33
33
  end
34
- expected = "<nav class=\"navbar navbar-light navbar-expand-lg\"><a class=\"navbar-brand\" href=\"/\">Brand</a><button class=\"navbar-toggler hidden-sm-up\" type=\"button\" data-toggle=\"collapse\" data-target=\"##{ actual.id }\">☰</button><div class=\"collapse navbar-collapse\" id=\"#{ actual.id }\"><ul class=\"navbar-nav\"><li class=\"nav-item\"><a class=\"active nav-link\" href=\"#Home\">Home</a></li><li class=\"nav-item\"><a class=\"nav-link\" href=\"#profile\">Profile</a></li><li class=\"nav-item\"><a class=\"nav-link\" href=\"#messages\">Messages</a></li></ul><form type=\"form_tag\" position=\"right\" class=\"navbar-form form-inline my-lg-0 my-2\" action=\"#\" accept-charset=\"UTF-8\" method=\"post\"><input name=\"utf8\" type=\"hidden\" value=\"&#x2713;\" /><button class=\"btn-secondary btn\">Search</button></form><span class=\"navbar-text\">test</span></div></nav>"
34
+ expected = "<nav class=\"navbar navbar-light navbar-expand-lg\"><span class=\"navbar-brand\">Brand</span><button class=\"navbar-toggler hidden-sm-up\" type=\"button\" data-toggle=\"collapse\" data-target=\"##{ actual.id }\">☰</button><div class=\"navbar-collapse\" id=\"#{ actual.id }\"><ul class=\"navbar-nav\"><li class=\"nav-item\"><a class=\"active nav-link\" href=\"#Home\">Home</a></li><li class=\"nav-item\"><a class=\"nav-link\" href=\"#profile\">Profile</a></li><li class=\"nav-item\"><a class=\"nav-link\" href=\"#messages\">Messages</a></li></ul><form type=\"form_tag\" position=\"right\" class=\"navbar-form form-inline my-lg-0 my-2\" action=\"#\" accept-charset=\"UTF-8\" method=\"post\"><input name=\"utf8\" type=\"hidden\" value=\"&#x2713;\" /><button class=\"btn-secondary btn\">Search</button></form><span class=\"navbar-text\">test</span></div></nav>"
35
35
 
36
36
  assert_equal expected, actual.render
37
37
  end
@@ -43,7 +43,7 @@ class NavbarTest < ActionView::TestCase
43
43
  n.link 'Link', url: '#link'
44
44
  end
45
45
  end
46
- expected = "<nav class=\"bg-dark navbar navbar-dark navbar-expand-lg\"><a class=\"navbar-brand\" href=\"/\"><img src=\"/images/ruby-white\" /></a><button class=\"navbar-toggler hidden-sm-up\" type=\"button\" data-toggle=\"collapse\" data-target=\"##{ actual.id }\">☰</button><div class=\"collapse navbar-collapse\" id=\"#{ actual.id }\"><ul class=\"navbar-nav\"><li class=\"nav-item\"><a class=\"nav-link\" href=\"#link\">Link</a></li></ul></div></nav>"
46
+ expected = "<nav class=\"bg-dark navbar navbar-dark navbar-expand-lg\"><span class=\"navbar-brand\"><img src=\"/images/ruby-white\" /></span><button class=\"navbar-toggler hidden-sm-up\" type=\"button\" data-toggle=\"collapse\" data-target=\"##{ actual.id }\">☰</button><div class=\"navbar-collapse\" id=\"#{ actual.id }\"><ul class=\"navbar-nav\"><li class=\"nav-item\"><a class=\"nav-link\" href=\"#link\">Link</a></li></ul></div></nav>"
47
47
 
48
48
  assert_equal expected, actual.render
49
49
  end
@@ -33,7 +33,7 @@ class CardTest < ActionView::TestCase
33
33
  end
34
34
  p.footer 'Footer'
35
35
  end
36
- expected = "<div class=\"panel\"><div class=\"panel-header justify-content-between\"><div class=\"panel-title\">My header</div><div class=\"btn-group btn-group-sm\" role=\"group\"><button class=\"btn-outline-secondary btn btn-sm without-text\"><i title=\"Minimize\" class=\"glyph fas fa-caret-up\"></i></button><button class=\"btn-outline-secondary btn btn-sm without-text\"><i title=\"Options\" class=\"glyph fas fa-cog\"></i></button><button class=\"btn-outline-secondary btn btn-sm without-text\"><i title=\"Close\" class=\"glyph fas fa-Close\"></i></button></div></div><div class=\"btn-toolbar justify-content-between panel-toolbar\" role=\"toolbar\"><div role=\"group\" class=\"btn-group btn-group-sm mr-2\"><button class=\"btn-secondary btn btn-sm\">Copy</button><button class=\"btn-secondary btn btn-sm\">Cut</button><button class=\"btn-secondary btn btn-sm\">Paste</button></div><div class=\"btn-group btn-group-sm\" role=\"group\"><button class=\"btn-secondary btn btn-sm\">Delete</button></div></div><div class=\"panel-body\">Body</div><div class=\"btn-toolbar panel-toolbar\" role=\"toolbar\"><div class=\"btn-group btn-group-sm\" role=\"group\"><button class=\"btn-success btn btn-sm without-text\"><i title=\"Add\" class=\"glyph fas fa-plus-circle\"></i></button><button class=\"btn-danger btn btn-sm without-text\"><i title=\"Remove\" class=\"glyph fas fa-minus-circle\"></i></button></div></div><div class=\"panel-footer\">Footer</div></div>"
36
+ expected = "<div class=\"panel\"><div class=\"panel-header justify-content-between\"><div class=\"panel-title\">My header</div><div class=\"btn-group btn-group-sm\" role=\"group\"><button class=\"btn-outline-secondary btn btn-sm without-text\"><i class=\"glyph fas fa-caret-up\"></i></button><button class=\"btn-outline-secondary btn btn-sm without-text\"><i class=\"glyph fas fa-cog\"></i></button><button class=\"btn-outline-secondary btn btn-sm without-text\"><i class=\"glyph fas fa-Close\"></i></button></div></div><div class=\"btn-toolbar justify-content-between panel-toolbar\" role=\"toolbar\"><div role=\"group\" class=\"btn-group btn-group-sm mr-2\"><button class=\"btn-secondary btn btn-sm\">Copy</button><button class=\"btn-secondary btn btn-sm\">Cut</button><button class=\"btn-secondary btn btn-sm\">Paste</button></div><div class=\"btn-group btn-group-sm\" role=\"group\"><button class=\"btn-secondary btn btn-sm\">Delete</button></div></div><div class=\"panel-body\">Body</div><div class=\"btn-toolbar panel-toolbar\" role=\"toolbar\"><div class=\"btn-group btn-group-sm\" role=\"group\"><button class=\"btn-success btn btn-sm without-text\"><i class=\"glyph fas fa-plus-circle\"></i></button><button class=\"btn-danger btn btn-sm without-text\"><i class=\"glyph fas fa-minus-circle\"></i></button></div></div><div class=\"panel-footer\">Footer</div></div>"
37
37
 
38
38
  assert_equal expected, actual
39
39
  end
@@ -225,8 +225,8 @@
225
225
  __getIcon: function(src) {
226
226
  if(typeof src == 'object'){
227
227
  var customIcon = this.$options.customIcons[src.name];
228
- console.log(customIcon)
229
- console.log(this.$options)
228
+ // console.log(customIcon)
229
+ // console.log(this.$options)
230
230
  return typeof customIcon == 'undefined' ? src.icon[this.$options.iconlibrary] : customIcon;
231
231
  } else {
232
232
  return src;
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ui_bibz
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.5
4
+ version: 2.3.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thooams
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-03-14 00:00:00.000000000 Z
11
+ date: 2019-04-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails