hr_lite 0.57.0 → 0.57.1

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: d9104f47987b7a8a7e613fd6d07ba269de6b1f2af1ecdd39eed2684b7a62f891
4
- data.tar.gz: 3a73e730997fefd65b794b47dc14d0c1d836ac60484ee32c5256f601d4cd8043
3
+ metadata.gz: 288b37a483def4fc57b059096e2ee8af708d1245dd2587119855635ea73d9c11
4
+ data.tar.gz: 65fe286df5fb17b8b369ab499b2980e3456b69f92b4f823f89c75e1053af7f35
5
5
  SHA512:
6
- metadata.gz: 89aae488789fee0bf918a04c4570ed9186860be2acadbca4647d314bd41a1d6008709d10bd341a1636639534086bac276e335e50b2753b1b02ff49f51e8cb241
7
- data.tar.gz: b152d8230fcccf6c6eb7dbcfbfc5152258d125fa3083a3dad7c439b1188059d01166f0e8ada8d7a5c25900f2223dbb5f192a8d4a502fee126ff4e8b210ae6dd4
6
+ metadata.gz: 955e1a2242f0c9585b219c5896b9069253624c9797aaa1028ecc7c068f5e5cde734af64ddfcf4982696a4b066e66bb322ed67e37a46d5b1587d5ff04e4d14ddc
7
+ data.tar.gz: 57ef0949c6c9f8e4569b8b0157b212ba52ad19f226541f5977d32f8773e1555e444b91eda89ccdc350df84c7bf9db51c279bfd3830aff994c487286c102a6693
data/CHANGELOG.md CHANGED
@@ -7,6 +7,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [0.57.1] - 2026-10-19
11
+
12
+ Forms in the host's iOS and Android staff apps (D24). No migrations.
13
+
14
+ - **A save shows its confirmation again.** Native pages reload on every Turbo visit, and the page Turbo fetched and threw away used to spend the flash. A GET fetched by Turbo in the app now keeps it for the reload.
15
+ - **A refused form keeps its errors and what was typed.** A 422 used to be discarded and the form reloaded blank. It is now drawn in place (with `turbo-cache-control: no-cache`), and the next visit reloads as before.
16
+ - Browsers are unchanged: they never load Turbo.
17
+
10
18
  ## [0.57.0] - 2026-10-19
11
19
 
12
20
  No migration.
@@ -9,6 +9,9 @@ module HrLite
9
9
  before_action :hr_authenticate!
10
10
  before_action :hr_set_current_actor
11
11
  around_action :hr_use_time_zone
12
+ # Native pages reload every Turbo visit (see the layout): the page Turbo
13
+ # fetched and threw away must not spend the flash the reload shows.
14
+ after_action -> { flash.keep if request.get? && request.headers["X-Turbo-Request-Id"] && HrLite.config.native_app.call(request) }
12
15
 
13
16
  helper_method :hr_current_user, :hr_admin?, :hr_leadership?, :hr_superadmin?, :hr_operations?, :hr_display_name,
14
17
  :hr_can?, :hr_reaches?, :hr_access
@@ -10,8 +10,14 @@
10
10
  <% if HrLite.config.native_app.call(request) %>
11
11
  <%# The host's iOS/Android shells drive pages through Turbo. "reload" makes
12
12
  every visit a full page load, so the plain scripts below run exactly
13
- as they do in a browser. Browsers never load Turbo here. %>
14
- <meta name="turbo-visit-control" content="reload">
13
+ as they do in a browser. Browsers never load Turbo here. A refused
14
+ form (422) is drawn in place instead: the reload would bring the form
15
+ back blank, with no error. no-cache keeps that render out of history. %>
16
+ <% if response.unprocessable? %>
17
+ <meta name="turbo-cache-control" content="no-cache">
18
+ <% else %>
19
+ <meta name="turbo-visit-control" content="reload">
20
+ <% end %>
15
21
  <%= javascript_include_tag "hr_lite/vendor/turbo.min", type: "module" %>
16
22
  <% end %>
17
23
  <%= stylesheet_link_tag "hr_lite/hr_lite", media: "all" %>
@@ -1,3 +1,3 @@
1
1
  module HrLite
2
- VERSION = "0.57.0"
2
+ VERSION = "0.57.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hr_lite
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.57.0
4
+ version: 0.57.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - kshitiz sinha