lato_settings 3.0.8 → 3.0.9

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: 525594f56c292e482713630d6c0287ca0b58aaee3e4ea1ad5c224591601f53e3
4
- data.tar.gz: e4939ece85e9b5e58b7944655b753250a4d8f2ed885daf2c101bfbc4375010c9
3
+ metadata.gz: 344cb9bd875b8e2f79d5aa42376c97d66895092109eab6af77e578962a3e908a
4
+ data.tar.gz: d47ae3971d99b0d89b037297bc7bea4b3d90e9c87974df2d798e7a6623645721
5
5
  SHA512:
6
- metadata.gz: ee6612cde0a321a5f9a55911bd13c2eb528e8ced4384b6767a0977e898cd511870dbfddcb1ddfa4bd5895c539ff1329331f2076256ce33126ee4dfccf28272c3
7
- data.tar.gz: 4474836089cf715d7d978f3dfce0fe63ce960ca9b3c91fe17ed3f2a444d289259bdf214420c4d846bf399eef39a9c7656e4f289438168b542d05042ba85237dd
6
+ metadata.gz: ae5bdecc751184385138b77225ac05a7d1beac18ebc79ec778c4d7ec20ed85571c27352c3803decd0f38927e17a911bef5648eb08cc316598df6950221e34ab5
7
+ data.tar.gz: cba5f0c6e033fe893cd07013b7ef159b835010235f4afdcbd95a2482005f67e9adc22fca3c0c8995c5c30b294f88374bb605b778e2a31ed65cbb840a7cfa2241
data/README.md CHANGED
@@ -1,7 +1,11 @@
1
1
  # Lato Settings
2
2
  Manage application settings on Lato projects.
3
3
 
4
+ Setting values, keys, and labels are displayed as plain text in the administration interface, including values saved before upgrading. HTML in these fields is escaped.
5
+
4
6
  ## Installation
7
+
8
+ Requires Rails 8.1.3.1 or newer in the 8.1 series and Lato 3.25.0 or newer. Existing applications must install the new Lato session migration before deployment; previous sessions are invalidated.
5
9
  Add required dependencies to your application's Gemfile:
6
10
 
7
11
  ```ruby
@@ -36,14 +36,21 @@ module LatoSettings
36
36
  end
37
37
 
38
38
  def print_content(setting, content, type)
39
- raw "
40
- <div class=\"input-group input-group-sm\" data-controller=\"lato-copyclip\">
41
- <input type=\"text\" class=\"form-control\" placeholder=\"#{setting.label || setting.key}\" aria-label=\"#{setting.label || setting.key}\" aria-describedby=\"#{type}_#{setting.id}\" value=\"#{content}\" data-lato-copyclip-target=\"input\" readonly>
42
- <button class=\"btn btn-primary\" type=\"button\" id=\"#{type}_#{setting.id}\" data-lato-copyclip-target=\"button\" data-action=\"lato-copyclip#onButtonClick\" title=\"#{I18n.t('lato_settings.cta_copy')}\" aria-label=\"#{I18n.t('lato_settings.cta_copy')}\" data-copy-text=\"<i class='bi bi-clipboard-check'></i>\">
43
- <i class=\"bi bi-clipboard\"></i>
44
- </button>
45
- </div>
46
- "
39
+ label = setting.label || setting.key
40
+ button_id = "#{type}_#{setting.id}"
41
+ copy_label = I18n.t("lato_settings.cta_copy")
42
+
43
+ content_tag(:div, class: "input-group input-group-sm", data: { controller: "lato-copyclip" }) do
44
+ concat tag.input(type: "text", class: "form-control", placeholder: label,
45
+ aria: { label: label, describedby: button_id }, value: content, readonly: true,
46
+ data: { lato_copyclip_target: "input" })
47
+ concat content_tag(:button, type: "button", id: button_id, class: "btn btn-primary",
48
+ title: copy_label, aria: { label: copy_label },
49
+ data: { lato_copyclip_target: "button", action: "lato-copyclip#onButtonClick",
50
+ copy_text: "<i class='bi bi-clipboard-check'></i>" }) {
51
+ content_tag(:i, "", class: "bi bi-clipboard")
52
+ }
53
+ end
47
54
  end
48
55
  end
49
56
  end
@@ -1,3 +1,3 @@
1
1
  module LatoSettings
2
- VERSION = "3.0.8"
2
+ VERSION = "3.0.9"
3
3
  end
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lato_settings
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.8
4
+ version: 3.0.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gregorio Galante
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2026-01-25 00:00:00.000000000 Z
10
+ date: 1980-01-02 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: rails
@@ -16,28 +15,34 @@ dependencies:
16
15
  requirements:
17
16
  - - ">="
18
17
  - !ruby/object:Gem::Version
19
- version: 7.1.1
18
+ version: 8.1.3.1
19
+ - - "<"
20
+ - !ruby/object:Gem::Version
21
+ version: '8.2'
20
22
  type: :runtime
21
23
  prerelease: false
22
24
  version_requirements: !ruby/object:Gem::Requirement
23
25
  requirements:
24
26
  - - ">="
25
27
  - !ruby/object:Gem::Version
26
- version: 7.1.1
28
+ version: 8.1.3.1
29
+ - - "<"
30
+ - !ruby/object:Gem::Version
31
+ version: '8.2'
27
32
  - !ruby/object:Gem::Dependency
28
33
  name: lato
29
34
  requirement: !ruby/object:Gem::Requirement
30
35
  requirements:
31
36
  - - ">="
32
37
  - !ruby/object:Gem::Version
33
- version: '0'
38
+ version: 3.25.0
34
39
  type: :runtime
35
40
  prerelease: false
36
41
  version_requirements: !ruby/object:Gem::Requirement
37
42
  requirements:
38
43
  - - ">="
39
44
  - !ruby/object:Gem::Version
40
- version: '0'
45
+ version: 3.25.0
41
46
  description: A Rails engine to manage application settings on Lato projects!
42
47
  email:
43
48
  - me@gregoriogalante.com
@@ -80,7 +85,6 @@ licenses:
80
85
  metadata:
81
86
  homepage_uri: https://github.com/Lato-org/lato_settings
82
87
  source_code_uri: https://github.com/Lato-org/lato_settings
83
- post_install_message:
84
88
  rdoc_options: []
85
89
  require_paths:
86
90
  - lib
@@ -95,8 +99,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
95
99
  - !ruby/object:Gem::Version
96
100
  version: '0'
97
101
  requirements: []
98
- rubygems_version: 3.4.1
99
- signing_key:
102
+ rubygems_version: 4.0.9
100
103
  specification_version: 4
101
104
  summary: Another engine for Lato projects
102
105
  test_files: []