Skip to content

Commit 9a7d24d

Browse files
committed
fix: hide V3 password rule icons when JS off
The check/close icons next to each rule are Alpine-driven state. Without JS, the pass icon rendered unconditionally and falsely suggested every rule was satisfied. Cloak both icon spans so the rule labels still serve as a static reference list while the live state markers stay hidden until Alpine takes over.
1 parent 6a81c4b commit 9a7d24d

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

templates/v3/includes/_field_password.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@
137137
{% with i=forloop.counter0 %}
138138
<li class="field__checklist-item"
139139
:class="rules[{{ i }}] && { 'field__checklist-item--pass': ruleState(rules[{{ i }}]) === 'pass', 'field__checklist-item--fail': ruleState(rules[{{ i }}]) === 'fail' }">
140-
<span x-show="!rules[{{ i }}] || ruleState(rules[{{ i }}]) !== 'fail'">
140+
<span x-cloak x-show="!rules[{{ i }}] || ruleState(rules[{{ i }}]) !== 'fail'">
141141
{% include "includes/icon.html" with icon_name="check" icon_size=16 %}
142142
</span>
143143
<span x-cloak

0 commit comments

Comments
 (0)