tramway 2.2.3 → 2.2.3.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:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: c3404f527f0941b117509108d7827d36cdf2c2d80037bdd41d6316ad040c2b95
|
|
4
|
+
data.tar.gz: 5a2896ae1e85140de75fa5c8b7aabc50475adf6ce31edeee66cfb1dd2d9cb034
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 11325a08313cf4eea578d73e5471b38339837f2f28b5af7e72a01d1eac6b72a493b12058135b8bd2f024608626ff9d84643c5d4d173c8b7fd561e41da2bd358c
|
|
7
|
+
data.tar.gz: bbd34d3d7fe3f8a7b306a7d79b0c8a328968180a270db57b2c89c490d5a115b68ee534ea75be48c39d60da13b45402288a6a6ea6b72f0db57d7c17a6d293d88a
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
= link_to path, class: classes, **render_options do
|
|
14
14
|
= content
|
|
15
15
|
- when :button
|
|
16
|
-
%button{
|
|
16
|
+
%button{ class: classes, **render_options }
|
|
17
17
|
= content
|
|
18
18
|
- when :form
|
|
19
19
|
= helpers.button_to path, method:, class: classes, form: form_options, **render_options do
|
|
@@ -5,6 +5,7 @@ require 'tramway/utils/field'
|
|
|
5
5
|
module Tailwinds
|
|
6
6
|
module Form
|
|
7
7
|
# Provides Tailwind-styled forms
|
|
8
|
+
# rubocop:disable Metrics/ClassLength
|
|
8
9
|
class Builder < Tramway::Views::FormBuilder
|
|
9
10
|
include Tramway::Utils::Field
|
|
10
11
|
|
|
@@ -92,7 +93,14 @@ module Tailwinds
|
|
|
92
93
|
def submit(action, **options, &)
|
|
93
94
|
sanitized_options = sanitize_options(options)
|
|
94
95
|
|
|
95
|
-
render(
|
|
96
|
+
render(
|
|
97
|
+
Tailwinds::ButtonComponent.new(
|
|
98
|
+
text: action,
|
|
99
|
+
size: form_size,
|
|
100
|
+
options: sanitized_options.merge(name: :commit, type: :submit)
|
|
101
|
+
),
|
|
102
|
+
&
|
|
103
|
+
)
|
|
96
104
|
end
|
|
97
105
|
|
|
98
106
|
private
|
|
@@ -140,5 +148,6 @@ module Tailwinds
|
|
|
140
148
|
end
|
|
141
149
|
end
|
|
142
150
|
end
|
|
151
|
+
# rubocop:enable Metrics/ClassLength
|
|
143
152
|
end
|
|
144
153
|
end
|
data/lib/tramway/version.rb
CHANGED