1"use strict"; 2 3/** 4 * 確èªãã¿ã³ã¯ãªã㯠5 */ 6$(document).on('click', '.btn-confirm', function(){ 7 8 // ãã®ã¿ã¤ãã³ã°ã§å度確èªç»é¢ã«æ¿å ¥ 9 SB_CF7.confirm_values(); 10 11 if(SB_CF7.validation(function(){ 12 SB_CF7.kana('[name="contact-kana"]'); 13 SB_CF7.zip('[name="contact-zip"]'); 14 SB_CF7.tel('[name="contact-tel"]'); 15 SB_CF7.email('[name="contact-email"]'); 16 const confirm_email_valid = SB_CF7.email('[name="contact-email-confirm"]'); 17 if(confirm_email_valid){ 18 SB_CF7.same('[name="contact-email-confirm"]', '[name="contact-email"]', 'ã¡ã¼ã«ã¢ãã¬ã¹'); 19 } 20 21 const requiredInputs = document.querySelectorAll('[aria-required="true"]'); 22 const contact_style = document.querySelector('[name="contact-style"]:checked'); 23 requiredInputs.forEach(input => { 24 let valid = true; 25 26 if(input.name === 'contact-shop'){ 27 if(input.value === "" && contact_style.value === 'åºè'){ 28 valid = false; 29 } 30 } else if(input.name === 'contact-school'){ 31 if(input.value === "" && contact_style.value === 'ã¹ã¯ã¼ã«'){ 32 valid = false; 33 } 34 } else if(input.name === 'contact-golfrange'){ 35 if(input.value === "" && contact_style.value === 'ã´ã«ãç·´ç¿å ´'){ 36 valid = false; 37 } 38 } else { 39 if(input.value === ""){ 40 valid = false; 41 } 42 } 43 44 if(! valid){ 45 const cf7_form_input = input.closest('.sb-cf7-input'); 46 const cf7_error = cf7_form_input.querySelector('.sb-cf7-error'); 47 cf7_error.innerHTML = SB_CF7.error_messages.required; 48 SB_CF7.validation_status = false; 49 } 50 }); 51 52 // acceptance 53 const acceptances = document.querySelectorAll('.wpcf7-acceptance input[type="checkbox"]'); 54 acceptances.forEach(input => { 55 if(!input.checked){ 56 const cf7_form_input = input.closest('.sb-cf7-input'); 57 const cf7_error = cf7_form_input.querySelector('.sb-cf7-error'); 58 cf7_error.innerHTML = SB_CF7.error_messages.accept; 59 SB_CF7.validation_status = false; 60 } 61 }); 62 })){ 63 64 65 // ããªãã¼ã·ã§ã³ãæå 66 $('.input').fadeOut(); 67 $('.confirm').fadeIn(); 68 } 69 70 setTimeout(function(){ 71 $('html, body').animate({ 72 scrollTop: $('.contact-content').offset().top 73 }, 400); 74 },100); 75 76}); 77 78 79/** 80 * æ»ããã¿ã³ã¯ãªã㯠81 */ 82$(document) 83 .ready(function(){ 84 SB_CF7.submit_once(); 85 86 // éä¿¡ãã¿ã³ãã¯ãªãã¯ããå ´åã®å¦ç 87 document.addEventListener('wpcf7mailsent', (event) => { 88 location = window.rooturl + 'contact/complete/'; 89 }, false); 90 }) 91 .on('keyup', '#AjaxZip3_zip', function(){ 92 AjaxZip3.zip2addr( this, '', 'contact-pref', 'contact-address'); 93 }) 94 .on('click', '.back', function(){ 95 // ããªãã¼ã·ã§ã³ãæå 96 $('.input').fadeIn(); 97 $('.confirm').fadeOut(); 98 setTimeout(function(){ 99 $('html, body').animate({ 100 scrollTop: $('.contact-content').offset().top 101 }, 400); 102 },100); 103 }) 104 .on('blur change keyup', '[name]', function(e){ 105 const value = $(this).val(); 106 const input_name = $(this).attr('name'); 107 const confirm_name = '.confirm-' + input_name; 108 $(confirm_name).html(value); 109 }) 110 .on('change','[name="contact-style"]',function(){ 111 $('.contact-shop-section, .contact-school-section, .contact-golfrange-section').removeClass('show'); 112 $('[name="contact-shop"],[name="contact-school"],[name="contact-golfrange"]').val(''); 113 if($(this).val() === 'åºè'){ 114 $('.contact-shop-section').addClass('show'); 115 } else if($(this).val() === 'ã¹ã¯ã¼ã«'){ 116 $('.contact-school-section').addClass('show'); 117 } else if($(this).val() === 'ã´ã«ãç·´ç¿å ´'){ 118 $('.contact-golfrange-section').addClass('show'); 119 } 120 });
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.