lato 0.1.33 → 0.1.35

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d80f200ab351b66a3fb875550a75df337fe39484dd97e64089fb69e71ad24380
4
- data.tar.gz: bac614240a6d9147177c0a84ed56ccb173a8628de46d8e6212a1bc29c8d9b4c7
3
+ metadata.gz: a7bc26a6247cd1ea0aef77e6ee1c6a5800733e322a45939c8dd9cb86e9b796e4
4
+ data.tar.gz: 9dde859008c95e04a05c891c6ec80ed7c52f3110af29207733014c81c16481ae
5
5
  SHA512:
6
- metadata.gz: f7c2e3bd766ad2e48197d889d75debb425077bfdfde9b7e70153c22fbc37b6e0eaec9c27f1c3776d2417d90625e8778ab6d7e4115f36bc1e142c242510e5b933
7
- data.tar.gz: f6ae26961ccbca3f0b83747f4527d2995722b3e700cecc2c228df8cb5a344301bffc840cb65423f1f4b030c0ff9818b21474859fd84ab004fe9e57be233d98f9
6
+ metadata.gz: c8357e4d168d5c239af75e590805a98b369673920d4ed888ec458a1299279bd821ad04489ae534ee49b83c57ea1fc9d19adffbb067a19d1bab6e2c4454ecc653
7
+ data.tar.gz: 2d1e43738d5870ff4dbf96ab6ee7f38f1b74d63ef4c2886ab9e27b5c98c4ad2ebee518ec9a9830386a472319aaf52ce1c489cfec5d62a5392f6ac1f6a4d80c57
@@ -7,6 +7,7 @@ module Lato
7
7
  # NOTE: instance variables are for options used by "lato_index" component helper
8
8
  key = options[:key] || 'default'
9
9
  pagination = options[:pagination] || false
10
+ default_sort_by = options[:default_sort_by] || nil
10
11
  @_lato_index ||= {}
11
12
  @_lato_index[key] = {
12
13
  columns: options[:columns] || collection.column_names || [],
@@ -14,6 +15,9 @@ module Lato
14
15
  searchable_columns: options[:searchable_columns] || []
15
16
  }
16
17
 
18
+ # manage default sort by parameter
19
+ params[:sort_by] = default_sort_by if params[:sort_by].blank? && default_sort_by
20
+
17
21
  # manage sort by parameter
18
22
  unless params[:sort_by].blank?
19
23
  sort_by_splitted = params[:sort_by].split('|')
@@ -0,0 +1 @@
1
+ <!-- Free for foot tags -->
@@ -0,0 +1 @@
1
+ <!-- Free for head tags -->
@@ -10,6 +10,8 @@
10
10
  <!-- TEMPORARY FIX: Popper js not working using bootstrap-gem -->
11
11
  <script src="https://cdn.jsdelivr.net/npm/@popperjs/core@2.9.2/dist/umd/popper.min.js" integrity="sha384-IQsoLXl5PILFhosVNubq5LC7Qb9DXgDA9i+tQ8Zj3iwWAwPtgFTxbJ8NT4GN1R8p" crossorigin="anonymous"></script>
12
12
 
13
+ <%= render 'layouts/lato/head_content' %>
14
+
13
15
  <%= stylesheet_link_tag Lato.config.assets_stylesheet_entry, media: "all" %>
14
16
  <%= javascript_importmap_tags %>
15
17
  </head>
@@ -43,5 +45,7 @@
43
45
  <%= render 'layouts/lato/aside-opener' %>
44
46
  <%= render 'layouts/lato/feedbacks' %>
45
47
  <%= render 'layouts/lato/action' %>
48
+
49
+ <%= render 'layouts/lato/foot_content' %>
46
50
  </body>
47
51
  </html>
data/lib/lato/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Lato
2
- VERSION = "0.1.33"
2
+ VERSION = "0.1.35"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lato
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.33
4
+ version: 0.1.35
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gregorio Galante
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-02-22 00:00:00.000000000 Z
11
+ date: 2023-03-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -174,7 +174,9 @@ files:
174
174
  - app/views/layouts/lato/_aside-opener.html.erb
175
175
  - app/views/layouts/lato/_content.html.erb
176
176
  - app/views/layouts/lato/_feedbacks.html.erb
177
+ - app/views/layouts/lato/_foot_content.html.erb
177
178
  - app/views/layouts/lato/_footer.html.erb
179
+ - app/views/layouts/lato/_head_content.html.erb
178
180
  - app/views/layouts/lato/_mailer-foot_content.html.erb
179
181
  - app/views/layouts/lato/_mailer-head_content.html.erb
180
182
  - app/views/layouts/lato/_navbar-brand_content.html.erb