lato 3.11.6 → 3.11.8
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 +4 -4
- data/app/assets/javascripts/lato/controllers/lato_index_controller.js +17 -0
- data/app/assets/stylesheets/lato/application.scss +5 -0
- data/app/helpers/lato/components_helper.rb +14 -0
- data/app/views/lato/components/_index.html.erb +2 -2
- data/lib/lato/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f05b67d482485eda6335b24f463fa5fd8de9b339ad75e2f01919179d18d64300
|
4
|
+
data.tar.gz: 6141f29a7f830da8a61060b5d13f10b1f4dc2304bf7e191e1004c7425c4a746b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9291584af35ac2a3a9af5e1b1decf622ca5b9f677901c37e6dd30c70c3008e0e1bc6cd2f0ced9028c9c901d6c2097b39ad94bd86b8165515515be244eb4b239c
|
7
|
+
data.tar.gz: d094a873bdb96294c3d002c8963850a0cc7b3c3c6d905e89728c12e41dc7e4ae687858c7f031c5ac73f7224fe458c52e3d6a8e3c7acf743d05bf32093c325a84
|
@@ -0,0 +1,17 @@
|
|
1
|
+
import { Controller } from "@hotwired/stimulus"
|
2
|
+
|
3
|
+
export default class extends Controller {
|
4
|
+
|
5
|
+
/**
|
6
|
+
* Stimulus
|
7
|
+
*/
|
8
|
+
|
9
|
+
connect() {
|
10
|
+
}
|
11
|
+
|
12
|
+
onSearchKeyUp(e) {
|
13
|
+
// Search the input with name "page" inside this.element and force value to 1
|
14
|
+
const pageInput = this.element.querySelector('input[name="page"]')
|
15
|
+
if (pageInput) pageInput.value = 1
|
16
|
+
}
|
17
|
+
}
|
@@ -208,6 +208,20 @@ module Lato
|
|
208
208
|
form.datetime_field key, options
|
209
209
|
end
|
210
210
|
|
211
|
+
def lato_form_item_input_time(form, key, options = {})
|
212
|
+
_lato_form_input_options(form, key, options, :change, 'form-control')
|
213
|
+
|
214
|
+
form.time_field key, options
|
215
|
+
end
|
216
|
+
|
217
|
+
def lato_form_item_input_color(form, key, options = {})
|
218
|
+
_lato_form_input_options(form, key, options, :change, 'form-control')
|
219
|
+
options[:class] ||= []
|
220
|
+
options[:class].push('lato-form-item-input-color')
|
221
|
+
|
222
|
+
form.color_field key, options
|
223
|
+
end
|
224
|
+
|
211
225
|
def lato_form_submit(form, label, options = {})
|
212
226
|
options[:class] ||= []
|
213
227
|
options[:class].push('btn')
|
@@ -7,7 +7,7 @@ collection_total = collection.respond_to?(:total_count) ? collection.total_count
|
|
7
7
|
|
8
8
|
<%= turbo_frame_tag "lato_index_#{key}_#{model_name_underscore}", class: "lato-index #{browser.device.mobile? ? 'lato-index-mob' : 'lato-index-desk'}" do %>
|
9
9
|
|
10
|
-
<%= form_tag request.path, method: :get, data: { controller: 'lato_form', turbo_frame: '_self' } do %>
|
10
|
+
<%= form_tag request.path, method: :get, data: { controller: 'lato_form lato_index', turbo_frame: '_self' } do %>
|
11
11
|
<%= hidden_field_tag :key, key %>
|
12
12
|
<% params.each do |k, v| %>
|
13
13
|
<%= hidden_field_tag k, v %>
|
@@ -17,7 +17,7 @@ collection_total = collection.respond_to?(:total_count) ? collection.total_count
|
|
17
17
|
<div class="d-flex mb-3">
|
18
18
|
<% if searchable_columns.any? %>
|
19
19
|
<div class="input-group">
|
20
|
-
<input type="text" name="search" class="form-control" placeholder="<%= I18n.t('lato.search_for') %>: <%= searchable_columns.map { |c| collection.model.human_attribute_name(c) }.to_sentence %>" value="<%= params[:search] %>">
|
20
|
+
<input type="text" name="search" class="form-control" placeholder="<%= I18n.t('lato.search_for') %>: <%= searchable_columns.map { |c| collection.model.human_attribute_name(c) }.to_sentence %>" value="<%= params[:search] %>" data-action="keyup->lato_index#onSearchKeyUp" aria-label="<%= I18n.t('lato.search') %>">
|
21
21
|
<button
|
22
22
|
class="btn btn-outline-primary"
|
23
23
|
type="submit"
|
data/lib/lato/version.rb
CHANGED
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: 3.11.
|
4
|
+
version: 3.11.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gregorio Galante
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-04-
|
11
|
+
date: 2025-04-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -161,6 +161,7 @@ files:
|
|
161
161
|
- app/assets/javascripts/lato/controllers/lato_form_controller.js
|
162
162
|
- app/assets/javascripts/lato/controllers/lato_guide_controller.js
|
163
163
|
- app/assets/javascripts/lato/controllers/lato_hello_controller.js
|
164
|
+
- app/assets/javascripts/lato/controllers/lato_index_controller.js
|
164
165
|
- app/assets/javascripts/lato/controllers/lato_input_autocomplete2_controller.js
|
165
166
|
- app/assets/javascripts/lato/controllers/lato_input_autocomplete_controller.js
|
166
167
|
- app/assets/javascripts/lato/controllers/lato_network_controller.js
|