lato 0.1.60 → 0.1.62

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7c9eb96e4d8465b539ddee7df568a3b9c37bdfb55e9b8b24ad3c5969a53c0e32
4
- data.tar.gz: b31a028a5f3dbdf18ba8f846bb0636ee77e967a1b96ebd858fef93cd882ec0d1
3
+ metadata.gz: da92b193a071f5710bad624118ba7af88a9fb443a0ea5ba203aecec0787872d8
4
+ data.tar.gz: 7e2b0a8fbaf7903179fa21730f5d69ba13bf687dd9fce82f49a129f4c3d442b8
5
5
  SHA512:
6
- metadata.gz: d150983fdebfba187569b988f957ca111030bc5617a64338cb90f13a9a4c635ab6fd10b88ada8f396615adb7d13cbf1bcef38decd9453962eb39bb16524864fb
7
- data.tar.gz: 8ddff51d4154bf41ee332bb6b8cd8eefcb7ad2c3d70040b2eebaeedd97fe4bdd602188750b36e6febaed02c8d225d385b455e62e21e8ffdd2ab5836d2f312950
6
+ metadata.gz: 78567b7e9045585557ab8fc242c095fc3ef94213d33ecc03771e58c3ccfc5a5665b10bbef113ebe8f7eaf98bf9995b8a68e165cfd6644b7746d3c879752ab72b
7
+ data.tar.gz: 2ecdaebc1d3b61e58b219240b875c912868299c7acb9d9cf5b86d1e08f32c6d18b1048311e96edce12ec7e66140d9449d3143a60cb90ff68e2c8576efc1a8b56
@@ -6,42 +6,13 @@ export default class extends Controller {
6
6
  'input'
7
7
  ]
8
8
 
9
- /**
10
- * Stimulus
11
- */
12
-
13
- connect() {
14
- this.originalFormData = this.loadFormData()
15
- this.disableSubmit()
16
- }
9
+ // NOTE: This controller is free for be used in future form improvements.
17
10
 
18
11
  /**
19
- * Functions
12
+ * Stimulus
20
13
  */
21
14
 
22
- disableSubmit() {
23
- if (!this.hasSubmitTarget) return
24
- this.submitTarget.setAttribute('disabled', true)
25
- }
26
-
27
- enableSubmit() {
28
- if (!this.hasSubmitTarget) return
29
- this.submitTarget.removeAttribute('disabled')
30
- }
31
-
32
- loadFormData() {
33
- const formData = {}
34
-
35
- this.inputTargets.forEach((input) => {
36
- if (input.type == 'checkbox') {
37
- formData[input.name] = input.checked
38
- } else {
39
- formData[input.name] = input.value
40
- }
41
- })
42
-
43
- return formData
44
- }
15
+ connect() {}
45
16
 
46
17
  /**
47
18
  * Actions
@@ -49,12 +20,5 @@ export default class extends Controller {
49
20
 
50
21
  onInputChange(e) {
51
22
  e.target.classList.remove('is-invalid')
52
-
53
- const formData = this.loadFormData()
54
- if (JSON.stringify(formData) != JSON.stringify(this.originalFormData)) {
55
- this.enableSubmit()
56
- } else {
57
- this.disableSubmit()
58
- }
59
23
  }
60
24
  }
@@ -6,7 +6,7 @@ module Lato
6
6
 
7
7
  before_action :find_user, only: %i[verify_email verify_email_action update_password update_password_action]
8
8
  before_action :find_invitation, only: %i[accept_invitation accept_invitation_action]
9
-
9
+
10
10
  before_action :lock_signup_if_disabled, only: %i[signup signup_action]
11
11
  before_action :lock_recover_password_if_disabled, only: %i[recover_password recover_password_action update_password update_password_action]
12
12
 
data/lib/lato/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Lato
2
- VERSION = "0.1.60"
2
+ VERSION = "0.1.62"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lato
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.60
4
+ version: 0.1.62
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gregorio Galante
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-08-24 00:00:00.000000000 Z
11
+ date: 2023-09-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -228,7 +228,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
228
228
  - !ruby/object:Gem::Version
229
229
  version: '0'
230
230
  requirements: []
231
- rubygems_version: 3.2.19
231
+ rubygems_version: 3.4.1
232
232
  signing_key:
233
233
  specification_version: 4
234
234
  summary: Basic engine for all Lato projects