inline_forms 7.13.4 → 7.13.5
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/CHANGELOG.md +22 -0
- data/app/controllers/inline_forms_controller.rb +1 -1
- data/docs/git-deps-assessment.md +106 -0
- data/lib/inline_forms/translation_record.rb +14 -0
- data/lib/inline_forms/version.rb +1 -1
- metadata +3 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 1852b024dd7d8d0b8f7b6d76e2ca17d4f8b9ad85dc6d2db6a4d11195164469e9
|
|
4
|
+
data.tar.gz: 6b9cfc0e042dc2d0146b282c779cc1cfaa547c7aaf0495bf897c125feaa16b45
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e6ddeccc3034c47c4e0ebd087e90222b3589b767bc24891f73f8caedd89cc24d06b3cd02b8242075ca8e2c27710aee494084b422eca61e6c8b110c7dc3ecac5a
|
|
7
|
+
data.tar.gz: 01b1d421b8d8ec544c4b41cb42e13d0f58634aee2ff07021edc5219adbd2b3cc4f6f4b5a0f7d8308e6a6e82eb457081965735a285065e465c3c36a716a33f71e
|
data/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,28 @@ All notable changes to this project are documented in this file.
|
|
|
4
4
|
|
|
5
5
|
## [Unreleased]
|
|
6
6
|
|
|
7
|
+
## [7.13.5] - 2026-05-19
|
|
8
|
+
|
|
9
|
+
### Changed
|
|
10
|
+
|
|
11
|
+
- **Generated app Gemfile — no more git forks for `tabs_on_rails` / `i18n-active_record`.**
|
|
12
|
+
- **`tabs_on_rails`:** `gem 'tabs_on_rails', '~> 3.0'` from RubyGems (weppos 3.0.0). The acesuares fork only added unused `:remote` on tab links; inline_forms uses `set_tab` only.
|
|
13
|
+
- **`i18n-active_record`:** removed. Generated apps never configured `I18n.backend`; only `extract_translations` read the `translations` SQL view. Replaced with **`InlineForms::TranslationRecord`** (`lib/inline_forms/translation_record.rb`) — read-only AR on the existing view (`thekey` column kept for MySQL).
|
|
14
|
+
- **`will_paginate`:** dropped commented acesuares git line; RubyGems only.
|
|
15
|
+
|
|
16
|
+
### Added
|
|
17
|
+
|
|
18
|
+
- **`docs/git-deps-assessment.md`** — fork history and verification notes (local copy also under `stuff/`, gitignored).
|
|
19
|
+
|
|
20
|
+
### Changed (also)
|
|
21
|
+
|
|
22
|
+
- **`InlineForms::VERSION`** and **`InlineFormsInstaller::VERSION`** → `7.13.5`.
|
|
23
|
+
|
|
24
|
+
### Verified
|
|
25
|
+
|
|
26
|
+
- `gem build inline_forms.gemspec` → `inline_forms-7.13.5.gem`; `gem build inline_forms_installer.gemspec` → `inline_forms_installer-7.13.5.gem`.
|
|
27
|
+
- `inline_forms create MyApp -d sqlite --example` → `bundle exec rails test` — **83 runs, 461 assertions, 0 failures, 0 errors, 0 skips** (Ruby 4.0.4 / Rails 7.2.3.1). `Gemfile.lock`: `tabs_on_rails (3.0.0)` from rubygems.org; no `i18n-active_record` git source.
|
|
28
|
+
|
|
7
29
|
## [7.13.4] - 2026-05-19
|
|
8
30
|
|
|
9
31
|
### Fixed
|
|
@@ -323,7 +323,7 @@ class InlineFormsController < ApplicationController
|
|
|
323
323
|
|
|
324
324
|
def extract_translations
|
|
325
325
|
keys_array = []
|
|
326
|
-
|
|
326
|
+
InlineForms::TranslationRecord.order(:locale, :thekey).each do |t|
|
|
327
327
|
keys_array << deep_hashify([ t.locale, t.thekey.split('.'), t.value ].flatten)
|
|
328
328
|
end
|
|
329
329
|
keys_hash = {}
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
# Git-sourced installer dependencies — assessment
|
|
2
|
+
|
|
3
|
+
**Date:** 2026-05-19
|
|
4
|
+
**Context:** Generated apps from `inline_forms create` used three non-RubyGems pins: `tabs_on_rails` (git + branch), `i18n-active_record` (git), and a commented `will_paginate` fork. This doc records why they existed and what replaced them.
|
|
5
|
+
|
|
6
|
+
**Related (risk callouts only):** `validation_hints/stuff/rails-7.2-zeitwerk-plan.md` (Track A3), `validation_hints/stuff/rails-8-checklist.md` (Phase 3).
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## Summary (7.13.5+)
|
|
11
|
+
|
|
12
|
+
| Gem | Was | Now | Reason |
|
|
13
|
+
|-----|-----|-----|--------|
|
|
14
|
+
| `will_paginate` | RubyGems + commented acesuares fork | RubyGems only | Fork never active; comment removed |
|
|
15
|
+
| `tabs_on_rails` | `acesuares/tabs_on_rails` branch `update_remote_before_action` | `~> 3.0` (weppos, RubyGems) | Fork only added unused `:remote` on tab links; upstream 3.0.0 already uses `before_action` |
|
|
16
|
+
| `i18n-active_record` | `acesuares/i18n-active_record` (2012) | **Removed** — `InlineForms::TranslationRecord` | App never sets `I18n.backend`; only reads the `translations` **view** via AR |
|
|
17
|
+
|
|
18
|
+
**No generated-app Gemfile should use `:git` for these anymore.**
|
|
19
|
+
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
## `will_paginate`
|
|
23
|
+
|
|
24
|
+
- **Fork:** `https://github.com/acesuares/will_paginate.git` (commented out for years).
|
|
25
|
+
- **Usage:** Nested/top-level list pagination in `_list.html.erb`; Turbo Frame nav since 7.5.x (no `:remote => true`).
|
|
26
|
+
- **Verdict:** RubyGems `will_paginate` is sufficient. No acesuares-specific behavior required.
|
|
27
|
+
|
|
28
|
+
---
|
|
29
|
+
|
|
30
|
+
## `tabs_on_rails`
|
|
31
|
+
|
|
32
|
+
### Why the fork existed
|
|
33
|
+
|
|
34
|
+
Branch `update_remote_before_action` on `acesuares/tabs_on_rails` (2019) did two things:
|
|
35
|
+
|
|
36
|
+
1. `before_filter` → `before_action` (Rails 4+ rename).
|
|
37
|
+
2. Optional `:remote => true` on `tab_for` links (`tabs_builder.rb`).
|
|
38
|
+
|
|
39
|
+
### What inline_forms actually uses
|
|
40
|
+
|
|
41
|
+
- Controllers call **`set_tab :resource`** only (generator template + installer).
|
|
42
|
+
- Top bar is **not** built with `tabs_tag` / `tab_for`; `_inline_forms_tabs.html.erb` is a Foundation top-bar with search + new button.
|
|
43
|
+
- Turbo migration removed **`data-remote`** from inline UI; no code passes `:remote` into tabs.
|
|
44
|
+
|
|
45
|
+
### Upstream today
|
|
46
|
+
|
|
47
|
+
- **RubyGems:** `tabs_on_rails` **3.0.0** (weppos, 2017).
|
|
48
|
+
- **`set_tab`** already uses **`before_action`** in `lib/tabs_on_rails/action_controller.rb`.
|
|
49
|
+
- **Missing vs fork:** `:remote` on tab links only — **unused by inline_forms**.
|
|
50
|
+
|
|
51
|
+
### Verdict
|
|
52
|
+
|
|
53
|
+
**Use `gem 'tabs_on_rails', '~> 3.0'`.** No runtime dependency on the fork. Re-test on Rails 7.2+ / 8.0 when upgrading (gem is unmaintained but tiny).
|
|
54
|
+
|
|
55
|
+
---
|
|
56
|
+
|
|
57
|
+
## `i18n-active_record`
|
|
58
|
+
|
|
59
|
+
### Why the fork existed
|
|
60
|
+
|
|
61
|
+
- Upstream expects a `translations` table with column **`key`**.
|
|
62
|
+
- MySQL reserves `KEY`; acesuares fork renamed to **`thekey`** with `alias_attribute :key, :thekey`.
|
|
63
|
+
- Fork is **Rails 3 era** (`set_table_name`, `attr_protected`, last push 2012).
|
|
64
|
+
|
|
65
|
+
### What inline_forms actually uses
|
|
66
|
+
|
|
67
|
+
- Installer builds **InlineFormsKey / Locale / Translation** tables, then a SQL **VIEW** `translations` with columns `locale`, **`thekey`**, `value`, `interpolations`, `is_proc`.
|
|
68
|
+
- **`I18n.backend` is never configured** to `I18n::Backend::ActiveRecord` in generated apps.
|
|
69
|
+
- Only consumer: **`InlineFormsController#extract_translations`** (admin export of keys); not wired in default routes/tests.
|
|
70
|
+
|
|
71
|
+
### Upstream today
|
|
72
|
+
|
|
73
|
+
- **RubyGems:** `i18n-active_record` **1.4.0** (2024), Rails 7.1+ YAML serializers, column **`key`**, optional `scope`.
|
|
74
|
+
- Adopting it would require renaming the view column to `key` (backtick on MySQL) and dropping the stale fork API.
|
|
75
|
+
|
|
76
|
+
### Verdict
|
|
77
|
+
|
|
78
|
+
**Drop the gem.** Add **`InlineForms::TranslationRecord`** (`lib/inline_forms/translation_record.rb`) as a read-only AR model on the existing view with **`thekey`**. Same behavior, no git dep, Rails 7.2-safe.
|
|
79
|
+
|
|
80
|
+
If full **I18n::Backend::ActiveRecord** is needed later, pin **`i18n-active_record ~> 1.4`** and align the view schema to upstream (`key` column + initializer), not the 2012 fork.
|
|
81
|
+
|
|
82
|
+
---
|
|
83
|
+
|
|
84
|
+
## Previously removed forks (reference)
|
|
85
|
+
|
|
86
|
+
| Gem | Removed in | Replacement |
|
|
87
|
+
|-----|------------|-------------|
|
|
88
|
+
| `devise-i18n` | 7.3.4 / 7.10+ | RubyGems `~> 1.16` |
|
|
89
|
+
| `paper_trail` | 7.0.x | RubyGems `~> 16.0` |
|
|
90
|
+
| `switch_user` | 7.2.x | Removed from installer |
|
|
91
|
+
|
|
92
|
+
---
|
|
93
|
+
|
|
94
|
+
## Verification
|
|
95
|
+
|
|
96
|
+
After changing `installer_core.rb`:
|
|
97
|
+
|
|
98
|
+
```bash
|
|
99
|
+
cd /home/code/inline_forms && rvm use . && gem build inline_forms.gemspec && gem build inline_forms_installer.gemspec
|
|
100
|
+
cd /home/code/testInline && rvm use .
|
|
101
|
+
gem install /home/code/inline_forms/inline_forms-*.gem /home/code/inline_forms/inline_forms_installer-*.gem
|
|
102
|
+
rm -rf MyApp && inline_forms create MyApp -d sqlite --example
|
|
103
|
+
cd MyApp && rvm use . && bundle exec rails test
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
Expect **0 failures**; `Gemfile.lock` should list `tabs_on_rails (3.0.0)` and **no** `i18n-active_record` git source.
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module InlineForms
|
|
4
|
+
# Read-only adapter for the +translations+ SQL view created by the installer
|
|
5
|
+
# (+inline_forms_create_view_for_translations+). The view exposes +thekey+
|
|
6
|
+
# (not +key+) so it works on MySQL where +key+ is reserved.
|
|
7
|
+
class TranslationRecord < ActiveRecord::Base
|
|
8
|
+
self.table_name = "translations"
|
|
9
|
+
|
|
10
|
+
def readonly?
|
|
11
|
+
true
|
|
12
|
+
end
|
|
13
|
+
end
|
|
14
|
+
end
|
data/lib/inline_forms/version.rb
CHANGED
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: 7.13.
|
|
4
|
+
version: 7.13.5
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ace Suares
|
|
@@ -493,6 +493,7 @@ files:
|
|
|
493
493
|
- archived/form_elements/tree/app/helpers/form_elements/move.rb
|
|
494
494
|
- archived/form_elements/tree/app/views/inline_forms/_show_tree.html.erb
|
|
495
495
|
- archived/form_elements/tree/app/views/inline_forms/_tree.html.erb
|
|
496
|
+
- docs/git-deps-assessment.md
|
|
496
497
|
- docs/jquery-widgets.md
|
|
497
498
|
- docs/prompt/.gitignore
|
|
498
499
|
- docs/prompt/test-the-example-app.md
|
|
@@ -553,6 +554,7 @@ files:
|
|
|
553
554
|
- lib/inline_forms/form_elements/text_field_helper.rb
|
|
554
555
|
- lib/inline_forms/form_elements/time_helper.rb
|
|
555
556
|
- lib/inline_forms/gem_files.rb
|
|
557
|
+
- lib/inline_forms/translation_record.rb
|
|
556
558
|
- lib/inline_forms/version.rb
|
|
557
559
|
- lib/locales/inline_forms.en.yml
|
|
558
560
|
- lib/locales/inline_forms.nl.yml
|