stimulus-password-strength 0.1.2 → 0.1.4

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: a0150f9398507c2a875986766bf55719e1301a68cc66a12591f1796354fc872f
4
- data.tar.gz: c469c7ec416cff1eb8dcb78f3a0a5cdd961a9d60110a317e1f6d9836727b442d
3
+ metadata.gz: 680420b026742db8f17192cf372b51fa045aa79a23551709f11eed0875ce2f61
4
+ data.tar.gz: 451f9156e8c9c49ea463161cfd0b7a8f00b6e21387e15f2b50300dbaee0dfc2c
5
5
  SHA512:
6
- metadata.gz: dc3c6f68e8ede33665fec285d0079d4cee0020b823b441bc8be08ea25c638862b656746ab5c9b359be1d3e055346c4a639c5ce4d9249c7e073cacb6f0c454189
7
- data.tar.gz: 8118612aa2c405d37dd6460a72aac666faec1317f8f6b0d98bcbcc6d039201f57a90fed64d36e3f4dcdd2e8fce198dae5abbdbca05ed8031869b19e62a50a420
6
+ metadata.gz: dfed9354d3578d4b0588081883fc37c66f003556379f1e13af8290b9248fd61d169364c1b59eae8d8d64dfb6e8f1caf16aa86866eb662fb8ecbb40b0b53f2ceb
7
+ data.tar.gz: ca2d4ca534ad631e78bb5deed5a996c9b8f8d82b7ab45f76e3419eb816bdf7c8525a73035b9a43167d05a4e374fe37414dfd7b7e964a6a191cc40cd3e7929233
data/AGENTS.md CHANGED
@@ -4,13 +4,38 @@ Use this file when an AI coding agent is integrating `stimulus-password-strength
4
4
 
5
5
  ## Goal
6
6
 
7
- Treat this gem as a UI layer for password UX, not as password security policy.
7
+ Treat this gem as a password UX simplification tool. Its purpose is to help the host app reduce signup friction while keeping backend security intentional.
8
8
 
9
9
  The integration should:
10
10
 
11
11
  - reduce signup friction
12
12
  - keep the meter visible even with 1Password/LastPass overlays
13
- - preserve backend validation until the host app intentionally migrates it
13
+ - make simplification decisions explicit instead of silently preserving legacy friction
14
+
15
+ ## Required Decision Prompts
16
+
17
+ Before integrating the gem into an existing app, inspect the current auth flow and ask the user explicit product/security questions when friction is detected.
18
+
19
+ At minimum, ask about:
20
+
21
+ 1. `password_confirmation`
22
+ - Example: `I detected password_confirmation in signup/reset. Do you want to keep it for compatibility, or simplify to a single password field with the gem's show/hide toggle?`
23
+ 2. Complex password policy
24
+ - Example: `I detected uppercase/lowercase/digit/special-char rules. Do you want to keep that policy, or simplify to a length-first policy and align the UI + backend?`
25
+ - If the user wants signup simplification, explicitly recommend reviewing whether composition rules can be removed in favor of a longer minimum length.
26
+ - Example: `I detected composition rules such as uppercase/digit/special character requirements. These usually add friction and reduce conversion. Do you want to replace them with a longer minimum length and remove the composition rules? The gem still gives users a password strength meter, so they can create a stronger, more memorable password instead of a forced hard-to-remember character mix.`
27
+ 3. Existing custom password UI
28
+ - Example: `I detected a custom password meter/toggle/controller. Do you want a full migration to the gem, or a partial rollout first?`
29
+ 4. Tests coupled to the old implementation
30
+ - Example: `I detected tests tied to custom password markup or password_confirmation. Do you want me to migrate them now to the new UX contract?`
31
+ 5. Rollout scope
32
+ - Example: `Do you want UI-only adoption first, or do you want the gem rollout to also simplify the auth flow in the same change?`
33
+ 6. Extra signup fields
34
+ - Example: `I detected a required username field during signup. If the app does not truly need usernames, do you want to simplify the form to just email + password? Extra fields usually increase signup time and abandonment risk.`
35
+ 7. Browser-level required validation
36
+ - Example: `I detected that some signup fields are not marked as required in the HTML. Do you want me to align the form with backend-required fields so users get immediate browser validation feedback?`
37
+
38
+ Do not make these simplification decisions silently. Detect them, explain the tradeoff, and ask.
14
39
 
15
40
  ## Recommended Rollout
16
41
 
@@ -31,9 +56,12 @@ bin/rails generate stimulus_password_strength:install
31
56
  - onboarding set password
32
57
  - admin-created account activation
33
58
  - forced password change
34
- 6. Do not remove `password_confirmation` if the host app still requires it.
35
- 7. Do not change backend validation during the first rollout unless validation is already wired to `PasswordPolicy`.
36
- 8. Roll out the UI first, then decide separately whether to simplify backend policy.
59
+ 6. If the host app has legacy friction such as `password_confirmation` or complex regex policy, ask whether that friction should be removed as part of this rollout.
60
+ 7. If the user chooses simplification, migrate backend validation, views, and tests together so the UX and policy stay aligned.
61
+ 8. If the user chooses compatibility, keep the existing policy but still move the UI to the gem.
62
+ 9. When simplification is chosen, prefer proposing a longer minimum length over uppercase/digit/special-character composition rules.
63
+ 10. Explain that the strength meter remains in place, so the user still gets guidance toward a strong password without being forced into brittle, hard-to-remember character patterns.
64
+ 11. Review whether signup can be reduced to just email + password. If `username` is not a real product requirement, recommend removing it.
37
65
 
38
66
  ## Host App Checks
39
67
 
@@ -44,14 +72,31 @@ Before changing any auth flow, verify:
44
72
  3. Are there custom validation messages that would drift from the new UI?
45
73
  4. Are there additional password flows outside signup and reset?
46
74
  5. Does the host app use a custom design system that should override helper classes?
75
+ 6. Are user-facing required fields also marked as `required` in the HTML where appropriate?
47
76
 
48
- ## What Not to Change Automatically
77
+ ## What Not to Change Silently
49
78
 
50
- 1. Do not remove `password_confirmation` without reviewing validations, tests, and reset flow behavior.
79
+ 1. Do not remove `password_confirmation` without confirming that simplification is desired and then updating validations, tests, and reset flow behavior.
51
80
  2. Do not change password policy just because the meter shows `good` or `strong`.
52
81
  3. Do not define `requirements` separately from `PasswordPolicy`.
53
82
  4. Do not hardcode hints such as `Must contain uppercase...` unless the backend actually enforces them.
54
83
  5. Do not assume Tailwind classes applied dynamically from JS will work in every host app.
84
+ 6. Do not rely only on backend validation when the browser can provide immediate required-field feedback safely.
85
+
86
+ ## Simplification Heuristic
87
+
88
+ If the app has obvious signup friction and the user has not stated a preference yet, lead with a recommendation to simplify:
89
+
90
+ 1. Prefer one password field over `password_confirmation` when the host app can support it.
91
+ 2. Prefer a length-first policy over composition rules when the product goal is conversion and the host app allows policy changes.
92
+ 3. If composition rules exist, ask whether they should be replaced with a sufficiently long minimum length rather than kept by default.
93
+ 4. When recommending that change, explain that the gem's strength meter still guides the user toward a hard-to-crack password while allowing more memorable passphrase-style choices.
94
+ 5. Prefer one shared `PasswordPolicy` for backend validation and gem requirements.
95
+ 6. Prefer behavior-based tests over markup-coupled tests.
96
+ 7. If signup asks for `username`, ask whether it is truly required. If not, recommend reducing the form to email + password.
97
+ 8. Ensure user-facing required fields are marked with the HTML `required` attribute when that matches backend expectations.
98
+
99
+ Then ask for confirmation before changing policy or contract.
55
100
 
56
101
  ## Minimal Smoke Test
57
102
 
data/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.1.4
4
+
5
+ - fixed a rendering bug where the password strength bar could stay visually hidden even though the label updated
6
+ - moved critical strength-bar and requirement layout fallbacks into inline styles so host-app Tailwind overrides cannot collapse the bar height or visibility
7
+ - preserved requirement base typography when pending/met/unmet states are updated in Stimulus
8
+ - expanded test coverage for the new style fallback properties and visible-bar behavior
9
+
10
+ ## 0.1.3
11
+
12
+ - clarified the public README around adaptive usage modes: UI-only integration vs conversion-focused signup simplification
13
+ - expanded `AGENTS.md` and `CLAUDE.md` so coding agents screen the host app before integration and ask explicit questions about password confirmation, composition rules, extra signup fields, and HTML `required` support
14
+ - documented the recommended simplification path: length-first password policy, one password field with show/hide, and email + password only when extra signup fields are not true product requirements
15
+
3
16
  ## 0.1.2
4
17
 
5
18
  - switched gem packaging to `git ls-files`
data/CLAUDE.md CHANGED
@@ -4,8 +4,13 @@ For integration guidance, treat [AGENTS.md](AGENTS.md) as the canonical source.
4
4
 
5
5
  ## Claude-Specific Notes
6
6
 
7
- 1. Start with a UI-only rollout unless the host app explicitly asks to simplify backend password policy.
8
- 2. Prefer using the generated `PasswordPolicy` as the source of truth for both model validation and gem requirements.
9
- 3. Update every user-facing password flow, not just signup.
10
- 4. If the host app still requires `password_confirmation`, keep it until validations and tests are migrated deliberately.
11
- 5. After integration, run a smoke test for signup, password reset, autofill, and password manager overlay behavior.
7
+ 1. Detect auth friction before changing code: `password_confirmation`, regex-heavy policy, custom password UI, and tests coupled to old markup.
8
+ 2. Ask explicit decision questions before assuming compatibility mode. This gem is meant to simplify auth UX, not only replace markup.
9
+ 3. If the app has uppercase/digit/special-character rules and the user wants simplification, ask whether they should be replaced with a longer minimum length to reduce signup friction.
10
+ 4. When making that recommendation, explain that the gem still provides a strength meter, so users are guided toward stronger and more memorable passwords instead of forced character patterns.
11
+ 5. If signup includes `username`, ask whether it is truly needed. If not, recommend reducing the form to email + password.
12
+ 6. Check whether user-facing required fields are also marked with the HTML `required` attribute so the browser can assist with validation immediately.
13
+ 7. If the user wants simplification, migrate policy, views, and tests together instead of doing UI-only halfway changes.
14
+ 8. Prefer using the generated `PasswordPolicy` as the source of truth for both model validation and gem requirements.
15
+ 9. Update every user-facing password flow, not just signup.
16
+ 10. After integration, run a smoke test for signup, password reset, autofill, and password manager overlay behavior.
data/README.md CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  Importmap-friendly password strength field for Rails 8+ with Stimulus, `zxcvbn`, and Tailwind-friendly markup.
4
4
 
5
+ Use it either as a drop-in password UX upgrade or as part of a broader signup simplification rollout. The same gem can support a conservative integration that only adds the strength meter and toggle, or a conversion-focused integration that helps remove unnecessary auth friction such as password confirmation, composition rules, or extra signup fields.
6
+
5
7
  ## Product Goal
6
8
 
7
9
  Reduce signup abandonment by improving password UX:
@@ -12,6 +14,11 @@ Reduce signup abandonment by improving password UX:
12
14
  - no Node.js required in the host app
13
15
  - simpler signup flow while keeping security standards and sound UX practices
14
16
 
17
+ This gem is intentionally adaptive. Depending on the host app and the user's product goal, it can be used in two valid modes:
18
+
19
+ - UI integration only: add the password strength meter, requirements, and show/hide toggle while keeping the existing auth policy
20
+ - conversion-focused simplification: use the gem rollout to simplify the signup flow, reduce unnecessary password friction, and improve registration completion
21
+
15
22
  ## What the Gem Includes
16
23
 
17
24
  - Rails engine: `StimulusPasswordStrength::Engine`
@@ -135,6 +142,42 @@ Adding more languages is standard Rails I18n: add another locale file in [config
135
142
  6. JS or `zxcvbn` failure: the form still allows submission.
136
143
  7. i18n: `show/hide/weak/fair/good/strong` labels are correct for the current locale.
137
144
 
145
+ ## Migrating from Custom Password UI
146
+
147
+ If the host app already has its own password strength UI, this is a migration, not a fresh install.
148
+
149
+ Typical signs:
150
+
151
+ - a custom Stimulus controller such as `password_field_controller.js`
152
+ - manual strength bar markup in signup or reset views
153
+ - a custom `zxcvbn` pin in `config/importmap.rb`
154
+ - tests tied to old DOM details such as `data-testid="password-input"`
155
+
156
+ Recommended migration order:
157
+
158
+ 1. Add the gem and run the installer.
159
+ 2. Move the real password rule into `PasswordPolicy`.
160
+ 3. Replace the custom password markup with `password_strength_field` in:
161
+ - signup / registration
162
+ - password reset / change password
163
+ 4. Remove the old password-specific Stimulus controller and its registration from `app/javascript/controllers/index.js`.
164
+ 5. Remove duplicate importmap pins if the app already pinned `zxcvbn` or a custom password controller setup.
165
+ 6. Update tests to target user-facing behavior, not the old internal DOM structure.
166
+
167
+ For example, prefer:
168
+
169
+ ```ruby
170
+ fill_in "Password", with: "SecurePass123!"
171
+ ```
172
+
173
+ instead of a selector tied to the old implementation:
174
+
175
+ ```ruby
176
+ find("[data-testid='password-input']").fill_in with: "SecurePass123!"
177
+ ```
178
+
179
+ After migration, there should be only one password UI implementation in the app: the gem-based one.
180
+
138
181
  ## Agent Guidance
139
182
 
140
183
  If you are installing this gem through an AI coding agent, use:
@@ -142,7 +185,7 @@ If you are installing this gem through an AI coding agent, use:
142
185
  - [AGENTS.md](AGENTS.md) for general agent instructions
143
186
  - [CLAUDE.md](CLAUDE.md) for Claude-specific workflow notes
144
187
 
145
- These files cover rollout order, host-app validation checks, smoke tests, and what should not be changed automatically.
188
+ These files contain agent-specific project screening, rollout, and simplification guidance. They tell the agent how to inspect the host app, which questions to ask before changing auth UX, and how to choose between compatibility mode and conversion-focused simplification. Keep that logic there, not in this README.
146
189
 
147
190
  ## Example Adaptation: `linked_flow`
148
191
 
@@ -152,20 +195,6 @@ The gem was also used in `../linked_flow` as an example of a more opinionated UX
152
195
  - the UI uses `password_strength_field`
153
196
  - backend validation and UI both use a shared `PasswordPolicy` with minimum password length
154
197
 
155
- Recommended rollout order:
156
-
157
- 1. Add the gem as UI-only.
158
- 2. Switch signup and reset views to `password_strength_field`.
159
- 3. Only then decide whether to simplify backend policy and business tests.
160
-
161
- ## Nice Follow-Ups After `0.1.0`
162
-
163
- 1. Generator for JS test scaffolding in the host app.
164
- 2. Wider CI coverage for Rails `8.0` and `8.1`.
165
- 3. `confirmation: true/false` helper option.
166
- 4. Public analytics event documentation for signup funnel instrumentation.
167
- 5. More examples for integrating with host app design systems.
168
-
169
198
  ## Development
170
199
 
171
200
  ```bash
@@ -175,8 +204,3 @@ npm install
175
204
  bundle exec rake test
176
205
  npm test
177
206
  ```
178
-
179
- ## Release Hygiene
180
-
181
- - full publication checklist: [PUBLISH_CHECKLIST.md](PUBLISH_CHECKLIST.md)
182
- - change history: [CHANGELOG.md](CHANGELOG.md)
@@ -31,6 +31,7 @@ export default class extends Controller {
31
31
  if (password.length === 0) {
32
32
  this.statusRowTarget.style.visibility = "hidden"
33
33
  this.strengthTrackTarget.style.visibility = "hidden"
34
+ this.strengthBarTarget.style.visibility = "hidden"
34
35
  this.strengthBarTarget.style.width = "0%"
35
36
  this.strengthBarTarget.style.backgroundColor = ""
36
37
  this.strengthTextTarget.textContent = ""
@@ -41,6 +42,7 @@ export default class extends Controller {
41
42
 
42
43
  this.statusRowTarget.style.visibility = "visible"
43
44
  this.strengthTrackTarget.style.visibility = "visible"
45
+ this.strengthBarTarget.style.visibility = "visible"
44
46
  const score = this.scoreFor(password)
45
47
  const widths = [10, 25, 50, 75, 100]
46
48
  const labels = ["weak", "weak", "fair", "good", "strong"]
@@ -131,7 +133,7 @@ export default class extends Controller {
131
133
  if (password.length === 0) {
132
134
  element.setAttribute("aria-hidden", "false")
133
135
  element.innerHTML = this.escapeHtml(element.dataset.label)
134
- element.style.cssText = `${element.dataset.pendingStyle}; visibility: visible;`
136
+ element.style.cssText = `${element.dataset.baseStyle}; ${element.dataset.pendingStyle}; visibility: visible;`
135
137
  return
136
138
  }
137
139
 
@@ -140,8 +142,8 @@ export default class extends Controller {
140
142
  ? this.metRequirementMarkup(element)
141
143
  : this.escapeHtml(this.requirementLabel(element, password))
142
144
  element.style.cssText = isMet
143
- ? `${element.dataset.metStyle}; visibility: visible;`
144
- : `${element.dataset.unmetStyle}; visibility: visible;`
145
+ ? `${element.dataset.baseStyle}; ${element.dataset.metStyle}; visibility: visible;`
146
+ : `${element.dataset.baseStyle}; ${element.dataset.unmetStyle}; visibility: visible;`
145
147
  })
146
148
  }
147
149
 
@@ -18,7 +18,7 @@
18
18
  <div class="<%= label_row_class %>">
19
19
  <%= form.label attribute, label, class: label_class %>
20
20
 
21
- <div class="<%= header_aux_class %>">
21
+ <div class="<%= header_aux_class %>" style="<%= header_aux_style %>">
22
22
  <% if requirements.any? %>
23
23
  <div class="<%= requirements_class %>" style="<%= requirements_style %>">
24
24
  <% requirements.each do |requirement| %>
@@ -32,8 +32,9 @@
32
32
  data-pending-style="<%= requirement_pending_style %>"
33
33
  data-met-style="<%= requirement_met_style %>"
34
34
  data-unmet-style="<%= requirement_unmet_style %>"
35
+ data-base-style="<%= requirement_style %>"
35
36
  class="<%= requirement_class %>"
36
- style="<%= requirement_pending_style %>"><%= requirement[:label] %></p>
37
+ style="<%= requirement_style %>; <%= requirement_pending_style %>"><%= requirement[:label] %></p>
37
38
  <% end %>
38
39
  </div>
39
40
  <% end %>
@@ -41,8 +42,8 @@
41
42
  </div>
42
43
 
43
44
  <div data-password-strength-target="statusRow" class="<%= status_row_class %>" style="<%= status_row_style %>; visibility: hidden;">
44
- <div data-password-strength-target="strengthTrack" class="<%= bar_track_class %>" style="visibility: hidden;">
45
- <div data-password-strength-target="strengthBar" class="<%= bar_base_class %>" style="width: 0%"></div>
45
+ <div data-password-strength-target="strengthTrack" class="<%= bar_track_class %>" style="<%= bar_track_style %>">
46
+ <div data-password-strength-target="strengthBar" class="<%= bar_base_class %>" style="<%= bar_style %>; width: 0%"></div>
46
47
  </div>
47
48
 
48
49
  <p data-password-strength-target="strengthText" class="<%= text_base_class %>" style="<%= text_style %>" aria-live="polite"></p>
@@ -61,15 +62,16 @@
61
62
  data-pending-style="<%= requirement_pending_style %>"
62
63
  data-met-style="<%= requirement_met_style %>"
63
64
  data-unmet-style="<%= requirement_unmet_style %>"
65
+ data-base-style="<%= requirement_style %>"
64
66
  class="<%= requirement_class %>"
65
- style="<%= requirement_pending_style %>"><%= requirement[:label] %></p>
67
+ style="<%= requirement_style %>; <%= requirement_pending_style %>"><%= requirement[:label] %></p>
66
68
  <% end %>
67
69
  </div>
68
70
  <% end %>
69
71
 
70
72
  <div data-password-strength-target="statusRow" class="<%= status_row_class %>" style="<%= status_row_style %>; visibility: hidden;">
71
- <div data-password-strength-target="strengthTrack" class="<%= bar_track_class %>" style="visibility: hidden;">
72
- <div data-password-strength-target="strengthBar" class="<%= bar_base_class %>" style="width: 0%"></div>
73
+ <div data-password-strength-target="strengthTrack" class="<%= bar_track_class %>" style="<%= bar_track_style %>">
74
+ <div data-password-strength-target="strengthBar" class="<%= bar_base_class %>" style="<%= bar_style %>; width: 0%"></div>
73
75
  </div>
74
76
 
75
77
  <p data-password-strength-target="strengthText" class="<%= text_base_class %>" style="<%= text_style %>" aria-live="polite"></p>
@@ -6,15 +6,19 @@ module StimulusPasswordStrength
6
6
  :label_row_class,
7
7
  :label_class,
8
8
  :header_aux_class,
9
+ :header_aux_style,
9
10
  :status_row_class,
10
11
  :status_row_style,
11
12
  :requirements_class,
12
13
  :requirements_style,
13
14
  :requirement_class,
15
+ :requirement_style,
14
16
  :input_class,
15
17
  :toggle_class,
16
18
  :bar_track_class,
19
+ :bar_track_style,
17
20
  :bar_base_class,
21
+ :bar_style,
18
22
  :text_base_class,
19
23
  :text_style,
20
24
  :hint_class,
@@ -29,17 +33,21 @@ module StimulusPasswordStrength
29
33
  @label_row_class = "flex items-end justify-between gap-3"
30
34
  @label_class = "block text-sm font-medium text-gray-700"
31
35
  @header_aux_class = "flex justify-end"
36
+ @header_aux_style = "display: flex; justify-content: flex-end; align-items: center;"
32
37
  @status_row_class = "flex min-h-5 items-center gap-2"
33
- @status_row_style = "min-height: 1rem;"
38
+ @status_row_style = "display: flex; align-items: center; gap: 0.5rem; min-height: 1rem;"
34
39
  @requirements_class = "flex justify-end gap-2"
35
- @requirements_style = "min-height: 1rem;"
40
+ @requirements_style = "display: flex; justify-content: flex-end; align-items: center; gap: 0.5rem; min-height: 1rem;"
36
41
  @requirement_class = "text-xs text-right leading-tight"
42
+ @requirement_style = "font-size: 0.75rem; line-height: 1rem; text-align: right;"
37
43
  @input_class = "w-full rounded-xl border border-gray-300 px-4 py-3 pr-16 shadow-sm focus:border-blue-500 focus:ring-2 focus:ring-blue-200"
38
44
  @toggle_class = "absolute right-3 top-1/2 -translate-y-1/2 cursor-pointer text-xs font-medium text-gray-500 hover:text-gray-700"
39
45
  @bar_track_class = "h-1.5 w-20 overflow-hidden rounded-full bg-gray-100"
46
+ @bar_track_style = "height: 0.375rem; width: 5rem; overflow: hidden; border-radius: 9999px; background-color: #f3f4f6; visibility: hidden; flex-shrink: 0;"
40
47
  @bar_base_class = "h-full rounded-full transition-all duration-300"
48
+ @bar_style = "display: block; height: 100%; border-radius: 9999px; visibility: hidden; transition: width 300ms ease, background-color 300ms ease;"
41
49
  @text_base_class = "text-xs"
42
- @text_style = "min-width: 2.5rem; text-align: right; white-space: nowrap;"
50
+ @text_style = "display: block; min-width: 2.5rem; text-align: right; white-space: nowrap;"
43
51
  @hint_class = "mt-1 text-xs text-gray-500"
44
52
  @requirement_pending_style = "color: #6b7280;"
45
53
  @requirement_met_style = "color: #047857;"
@@ -16,14 +16,18 @@ module StimulusPasswordStrength
16
16
  label_row_class = options.delete(:label_row_class) || config.label_row_class
17
17
  label_class = options.delete(:label_class) || config.label_class
18
18
  header_aux_class = options.delete(:header_aux_class) || config.header_aux_class
19
+ header_aux_style = options.delete(:header_aux_style) || config.header_aux_style
19
20
  status_row_class = options.delete(:status_row_class) || config.status_row_class
20
21
  status_row_style = options.delete(:status_row_style) || config.status_row_style
21
22
  requirements_class = options.delete(:requirements_class) || config.requirements_class
22
23
  requirements_style = options.delete(:requirements_style) || config.requirements_style
23
24
  requirement_class = options.delete(:requirement_class) || config.requirement_class
25
+ requirement_style = options.delete(:requirement_style) || config.requirement_style
24
26
  toggle_class = options.delete(:toggle_class) || config.toggle_class
25
27
  bar_track_class = options.delete(:bar_track_class) || config.bar_track_class
28
+ bar_track_style = options.delete(:bar_track_style) || config.bar_track_style
26
29
  bar_base_class = options.delete(:bar_base_class) || config.bar_base_class
30
+ bar_style = options.delete(:bar_style) || config.bar_style
27
31
  text_base_class = options.delete(:text_base_class) || config.text_base_class
28
32
  text_style = options.delete(:text_style) || config.text_style
29
33
  hint_class = options.delete(:hint_class) || config.hint_class
@@ -46,14 +50,18 @@ module StimulusPasswordStrength
46
50
  label_row_class: label_row_class,
47
51
  label_class: label_class,
48
52
  header_aux_class: header_aux_class,
53
+ header_aux_style: header_aux_style,
49
54
  status_row_class: status_row_class,
50
55
  status_row_style: status_row_style,
51
56
  requirements_class: requirements_class,
52
57
  requirements_style: requirements_style,
53
58
  requirement_class: requirement_class,
59
+ requirement_style: requirement_style,
54
60
  toggle_class: toggle_class,
55
61
  bar_track_class: bar_track_class,
62
+ bar_track_style: bar_track_style,
56
63
  bar_base_class: bar_base_class,
64
+ bar_style: bar_style,
57
65
  text_base_class: text_base_class,
58
66
  text_style: text_style,
59
67
  hint_class: hint_class,
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module StimulusPasswordStrength
4
- VERSION = "0.1.2"
4
+ VERSION = "0.1.4"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stimulus-password-strength
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Justyna Wojtczak