diff --git a/README.md b/README.md index 460a419..4741ff9 100644 --- a/README.md +++ b/README.md @@ -63,7 +63,8 @@ tarteaucitron.init({ "readmoreLink": "", /* Change the default readmore link pointing to tarteaucitron.io */ - "mandatory": true /* Show a message about mandatory cookies */ + "mandatory": true, /* Show a message about mandatory cookies */ + "mandatoryCta": true /* Show the disabled accept button when mandatory on */ }); ``` diff --git a/tarteaucitron.js b/tarteaucitron.js index 85b2f66..bf7f632 100644 --- a/tarteaucitron.js +++ b/tarteaucitron.js @@ -220,6 +220,7 @@ var tarteaucitron = { "useExternalCss": false, "useExternalJs": false, "mandatory": true, + "mandatoryCta": true, "closePopup": false, "groupServices": false, "serviceDefaultState": 'wait', @@ -365,14 +366,16 @@ var tarteaucitron = { html += ' ' + tarteaucitron.lang.mandatoryText + ''; html += '
'; html += ' '; - html += '
'; - html += ' '; - html += ' '; - html += '
'; + if (tarteaucitron.parameters.mandatoryCta == true) { + html += '
'; + html += ' '; + html += ' '; + html += '
'; + } html += ''; html += ''; }