diff options
Diffstat (limited to 'pkg/tpl/add_templ.go')
-rw-r--r-- | pkg/tpl/add_templ.go | 19 |
1 files changed, 3 insertions, 16 deletions
diff --git a/pkg/tpl/add_templ.go b/pkg/tpl/add_templ.go index 04fb615..d47582b 100644 --- a/pkg/tpl/add_templ.go +++ b/pkg/tpl/add_templ.go @@ -92,33 +92,20 @@ func AddQuotePage(form *AddQuoteForm, err string) templ.Component { if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } - _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("\"><div role=\"group\"><img class=\"captcha\" src=\"") + _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("\"> <img class=\"captcha\" src=\"") if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } var templ_7745c5c3_Var6 string templ_7745c5c3_Var6, templ_7745c5c3_Err = templ.JoinStringErrs(fmt.Sprintf("/captcha/download/%s.png", form.CaptchaID)) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `pkg/tpl/add.templ`, Line: 18, Col: 86} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `pkg/tpl/add.templ`, Line: 17, Col: 85} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var6)) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } - _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("\"> <audio id=\"audiocaptcha\" src=\"") - if templ_7745c5c3_Err != nil { - return templ_7745c5c3_Err - } - var templ_7745c5c3_Var7 string - templ_7745c5c3_Var7, templ_7745c5c3_Err = templ.JoinStringErrs(fmt.Sprintf("/captcha/download/%s.wav?lang=ru", form.CaptchaID)) - if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `pkg/tpl/add.templ`, Line: 19, Col: 98} - } - _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var7)) - if templ_7745c5c3_Err != nil { - return templ_7745c5c3_Err - } - _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("\"></audio> <a role=\"button\" onclick=\"togglePlay()\">Прослушать</a> <input type=\"text\" name=\"captcha_value\" placeholder=\"Код с картинки\"></div><input type=\"submit\" value=\"Отправить на модерацию\"></form><script>\n\t\t\tvar myAudio = document.getElementById(\"audiocaptcha\");\n\t\t\tvar isPlaying = false;\n\t\t\tfunction togglePlay() {\n\t\t\t\tisPlaying ? myAudio.pause() : myAudio.play();\n\t\t\t};\n\t\t\tmyAudio.onplaying = function() {\n\t\t\t\tisPlaying = true;\n\t\t\t};\n\t\t\tmyAudio.onpause = function() {\n\t\t\t\tisPlaying = false;\n\t\t\t};\n\t\t</script>") + _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("\"> <input type=\"text\" name=\"captcha_value\" placeholder=\"Код с картинки\"> <input type=\"submit\" value=\"Отправить на модерацию\"></form>") if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } |