Add alt title for audio button.

This commit is contained in:
rulingcom committed 2022-10-13 14:25:58 +08:00
1 parent aefc02d8a2
commit b7d7b6e9ae
4 files changed
+5 -2

No files matched your search

+1 -1
View File
@@ -22,7 +22,7 @@ module RuCaptcha
tag(:img, opts)
end
def rucaptcha_audio_tag()
"<button type=\"button\" onclick=\"document.getElementById(&quot;captcha_audio&quot;).play();\" class=\"fas fa-volume-up\" style=\"font-size: 1.5em; color: #333; cursor: pointer; border: 2px solid #333; padding: 0.2em;\"></button><audio id=\"captcha_audio\" src=\"#{ru_captcha.root_path(:format=>:wav)}\"></audio>".html_safe
"<button title=\"#{I18n.t('rucaptcha.play_captcha_voice')}\" type=\"button\" onclick=\"document.getElementById(&quot;captcha_audio&quot;).play();\" class=\"fas fa-volume-up\" style=\"font-size: 1.5em; color: #333; cursor: pointer; border: 2px solid #333; padding: 0.2em;\"></button><audio id=\"captcha_audio\" src=\"#{ru_captcha.root_path(:format=>:wav)}\"></audio>".html_safe
end
def gotcha(opts = {})
if opts[:placeholder].blank?