diff --git a/client/index.js b/client/index.js index 27137da..f4a2ca9 100644 --- a/client/index.js +++ b/client/index.js @@ -1,3 +1,6 @@ +/* Executed after page loading */ +(function () { + class JeanCloudContactFormNotifier { constructor (theme, messageContainer) { /* Choose the theme */ @@ -112,7 +115,6 @@ function jeanCloudContactFormIntercept (formId, notifier) { } } -(function () { /* Get the current js file location */ const path = (document.currentScript.src[-1] == '/' ? document.currentScript.src : document.currentScript.src.replace(/\/[^\/]*$/, '')) @@ -125,6 +127,15 @@ function jeanCloudContactFormIntercept (formId, notifier) { link.integrity = 'sha384-D12RSMaIURTgZZljhdQqYlQzgEfXvOFwtiqzkWnNcDbKFwMWXcmsCRFO5BNii0MB' // cat style.css | openssl dgst -sha384 -binary | openssl base64 -A document.head.appendChild(link); + + /* Load the targeted forms */ + var configs = document.getElementsByClassName('contact-form-config') + for (var i=0; i
-
+ - +
@@ -27,11 +27,10 @@
- +
- - +