Skip to content

Commit

Permalink
Add touchstart event to detection of user interaction. Fixes no-save …
Browse files Browse the repository at this point in the history
…bug on mobile sliders.
  • Loading branch information
jegelstaff committed Jan 14, 2025
1 parent c6be0e6 commit a8fdfca
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/formulize/include/formdisplay.php
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ public function renderValidationJS($withtags = true) {
global $actionFunctionName;
$js .= " jQuery('#".$this->getName()."').attr('action', ".$actionFunctionName."());\n";
if($this->tokenName) {
$js .= " jQuery(document).on('focusin click', 'p.auto_multi, input, select, textarea, div', function() {\n";
$js .= " jQuery(document).on('focusin click touchstart', 'p.auto_multi, input, select, textarea, div', function() {\n";
$js .= " setTimeout(function() {\n";
$js .= " jQuery('input[name=\"".$this->tokenName."\"]').val(\"".$this->tokenVal."\");\n";
$js .= " }, 269);\n";
Expand Down

0 comments on commit a8fdfca

Please sign in to comment.