inline_forms 8.1.42 → 8.1.44
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/.claude/settings.local.json +9 -0
- data/CHANGELOG.md +26 -0
- data/app/assets/stylesheets/inline_forms/inline_forms.scss +19 -0
- data/lib/inline_forms/form_elements/simple_file_field_helper.rb +5 -2
- data/lib/inline_forms/version.rb +1 -1
- data/test/integration/legacy_elements_test.rb +12 -0
- metadata +2 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: e8208cb1ccfd70968b65e5a5245b30586ab35034059749a20b4dc27ffde59bbe
|
|
4
|
+
data.tar.gz: 91f66242ff63e1d1c7ff22aa744939b05140f8b95cb8ac009956a1e70a2c9ca9
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 6c7060b4c597512ab705c0eb8f104dbdb754ca4aa121e9214906e15e8ba3c64a942159e1a2d6312509465c02ab72f5299973742f317746d6f5ee99399283460f
|
|
7
|
+
data.tar.gz: 4411cae2c459f7de8b46651abe65a12360854d7434232b6a283c29a9fae4647cc5b49b548ab87fced3847f4e155975de8cf44d5b6d9ff5c610e83248b197edb8
|
data/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,32 @@ All notable changes to this project are documented in this file.
|
|
|
4
4
|
|
|
5
5
|
## [Unreleased]
|
|
6
6
|
|
|
7
|
+
## [8.1.44] - 2026-07-24
|
|
8
|
+
|
|
9
|
+
### Fixed
|
|
10
|
+
|
|
11
|
+
- **`simple_file_field` download link bypasses Turbo and uses the correct route segment.** When a file is present, the show link now carries `data-turbo="false"` so the browser handles the host controller's `send_data` response natively instead of Turbo loading binary content into the frame. The href route method is read from the raw values hash entry (e.g. `{ 0 => "download" }`) instead of through `attribute_values`, which translated the segment via `t()` and produced broken URLs. Integration test in `legacy_elements_test.rb`.
|
|
12
|
+
|
|
13
|
+
### Lockstep
|
|
14
|
+
|
|
15
|
+
- validation_hints 8.1.44, inline_forms_installer 8.1.44, inline_forms_schema_edit 8.1.44.
|
|
16
|
+
|
|
17
|
+
## [8.1.43] - 2026-07-22
|
|
18
|
+
|
|
19
|
+
### Fixed
|
|
20
|
+
|
|
21
|
+
- **Native date/time/month/week/colour pickers show their picker control again.** Foundation's form reset (`_forms.scss`) applies `appearance: none` to a shared list of input types that includes `date`, `datetime-local`, `month`, `week`, `time`, and `color`. For plain text inputs that is harmless, but for the native `<input type="…">` pickers introduced in 8.1.25/8.1.26 (which replaced the jQuery UI date/time/month widgets) it stripped the browser's calendar/clock/month/colour indicator, leaving a bare text box with no way to open the picker. `inline_forms.scss` now restores `appearance: auto` for these input types (the `input[type=…]` selector outranks Foundation's `[type=…]`, so it wins regardless of source order).
|
|
22
|
+
|
|
23
|
+
### Merged
|
|
24
|
+
|
|
25
|
+
- Merges the `feature/schema-gui-pipeline` line (schema-GUI extraction, batch
|
|
26
|
+
pipeline, and the 8.1.42 `gem build` / release fixes) into `master` alongside
|
|
27
|
+
the picker fix above, so both lines ship together going forward.
|
|
28
|
+
|
|
29
|
+
### Lockstep
|
|
30
|
+
|
|
31
|
+
- validation_hints 8.1.43, inline_forms_installer 8.1.43, inline_forms_schema_edit 8.1.43.
|
|
32
|
+
|
|
7
33
|
## [8.1.42] - 2026-07-22
|
|
8
34
|
|
|
9
35
|
### Fixed
|
|
@@ -145,6 +145,25 @@ input {
|
|
|
145
145
|
margin: 2px 0 !important;
|
|
146
146
|
}
|
|
147
147
|
|
|
148
|
+
// Foundation's form reset (_forms.scss) lumps the native temporal/colour
|
|
149
|
+
// input types in with plain text inputs and applies `appearance: none` to
|
|
150
|
+
// normalize them. For the native <input type="date|time|month|week|color">
|
|
151
|
+
// pickers (8.1.25+, which replaced the jQuery UI date/time/month widgets)
|
|
152
|
+
// that strips the browser's calendar/clock/month/colour picker indicator,
|
|
153
|
+
// so the field renders as a bare text box with no way to open the picker.
|
|
154
|
+
// Restore the native appearance for these so their picker control shows.
|
|
155
|
+
// (`input[type=...]` is more specific than Foundation's `[type=...]`, so
|
|
156
|
+
// this wins regardless of source order.)
|
|
157
|
+
input[type="date"],
|
|
158
|
+
input[type="datetime-local"],
|
|
159
|
+
input[type="month"],
|
|
160
|
+
input[type="week"],
|
|
161
|
+
input[type="time"],
|
|
162
|
+
input[type="color"] {
|
|
163
|
+
-webkit-appearance: auto;
|
|
164
|
+
appearance: auto;
|
|
165
|
+
}
|
|
166
|
+
|
|
148
167
|
select {
|
|
149
168
|
background-color: var(--if-color-input-bg) !important;
|
|
150
169
|
border: 0 !important;
|
|
@@ -7,11 +7,14 @@ module InlineForms
|
|
|
7
7
|
|
|
8
8
|
def simple_file_field_show(object, attribute)
|
|
9
9
|
o = object.send(attribute)
|
|
10
|
-
|
|
10
|
+
attributes = @inline_forms_attribute_list || object.inline_forms_attribute_list
|
|
11
|
+
values = attributes.assoc(attribute.to_sym)[2]
|
|
12
|
+
raise "inline_forms: no values defined in #{object.class} for #{attribute} (add a values hash to the inline_forms_attribute_list row)" if values.nil?
|
|
13
|
+
method = values.is_a?(Hash) ? values.sort_by { |k, _| k }.first[1] : values.first
|
|
11
14
|
if o.send(:present?)
|
|
12
15
|
filename = o.to_s
|
|
13
16
|
model = object.class.to_s.pluralize.underscore
|
|
14
|
-
link_to filename, "/#{model}/#{method}/#{object.id}" # route must exist!!
|
|
17
|
+
link_to filename, "/#{model}/#{method}/#{object.id}", data: { turbo: false } # route must exist!! turbo:false so the browser downloads send_data natively instead of Turbo loading it into the frame
|
|
15
18
|
else
|
|
16
19
|
link_to_inline_edit object, attribute, "<i class='fi-plus'></i>".html_safe, from_callee: __callee__
|
|
17
20
|
end
|
data/lib/inline_forms/version.rb
CHANGED
|
@@ -20,6 +20,18 @@ class LegacyElementsTest < InlineFormsIntegrationTestCase
|
|
|
20
20
|
assert_includes response.body, "fi-plus"
|
|
21
21
|
end
|
|
22
22
|
|
|
23
|
+
test "simple_file_field present state download link bypasses Turbo" do
|
|
24
|
+
@widget.update!(manual: "Lida.png")
|
|
25
|
+
frame = "widget_#{@widget.id}"
|
|
26
|
+
get widget_path(@widget, update: frame), headers: frame_headers(frame)
|
|
27
|
+
|
|
28
|
+
assert_response :success
|
|
29
|
+
# The download link must carry data-turbo="false" so the browser handles
|
|
30
|
+
# the send_data response natively instead of Turbo loading the binary into
|
|
31
|
+
# the frame (a no-op). The route method comes from the values entry.
|
|
32
|
+
assert_match %r{<a[^>]*data-turbo="false"[^>]*href="/widgets/download/#{@widget.id}"}, response.body
|
|
33
|
+
end
|
|
34
|
+
|
|
23
35
|
test "simple_file_field edit renders a file input" do
|
|
24
36
|
frame = "widget_#{@widget.id}_manual"
|
|
25
37
|
get edit_widget_path(@widget, attribute: "manual",
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: inline_forms
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 8.1.
|
|
4
|
+
version: 8.1.44
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ace Suares
|
|
@@ -94,6 +94,7 @@ executables: []
|
|
|
94
94
|
extensions: []
|
|
95
95
|
extra_rdoc_files: []
|
|
96
96
|
files:
|
|
97
|
+
- ".claude/settings.local.json"
|
|
97
98
|
- ".document"
|
|
98
99
|
- ".forgejo/workflows/ci.yml"
|
|
99
100
|
- ".forgejo/workflows/full-gate.yml"
|