diff --git a/composer.json b/composer.json index bb4e755..4172175 100644 --- a/composer.json +++ b/composer.json @@ -39,6 +39,7 @@ "drupal/honeypot": "^1.29", "drupal/diff": "^1.0@RC", "drupal/menu_trail_by_path": "^1.1", + "drupal/antibot": "^1.2", "zaporylie/composer-drupal-optimizations": "^1.0" }, "repositories": { diff --git a/composer.lock b/composer.lock index b2b642f..ccb0a48 100644 --- a/composer.lock +++ b/composer.lock @@ -2521,6 +2521,53 @@ "source": "http://cgit.drupalcode.org/allowed_formats" } }, + { + "name": "drupal/antibot", + "version": "1.2.0", + "source": { + "type": "git", + "url": "https://git.drupal.org/project/antibot", + "reference": "8.x-1.2" + }, + "dist": { + "type": "zip", + "url": "https://ftp.drupal.org/files/projects/antibot-8.x-1.2.zip", + "reference": "8.x-1.2", + "shasum": "4cb067e77929984c8cf5b05a84734c62d6fd19b3" + }, + "require": { + "drupal/core": "~8.0" + }, + "type": "drupal-module", + "extra": { + "branch-alias": { + "dev-1.x": "1.x-dev" + }, + "drupal": { + "version": "8.x-1.2", + "datestamp": "1522335671", + "security-coverage": { + "status": "covered", + "message": "Covered by Drupal's security advisory policy" + } + } + }, + "notification-url": "https://packages.drupal.org/8/downloads", + "license": [ + "GPL-2.0-or-later" + ], + "authors": [ + { + "name": "mstef", + "homepage": "https://www.drupal.org/user/107190" + } + ], + "description": "Prevent forms from being submitted without JavaScript enabled", + "homepage": "https://www.drupal.org/project/antibot", + "support": { + "source": "http://cgit.drupalcode.org/antibot" + } + }, { "name": "drupal/better_normalizers", "version": "1.0.0-beta3", diff --git a/config/sync/antibot.settings.yml b/config/sync/antibot.settings.yml new file mode 100644 index 0000000..ed0c87b --- /dev/null +++ b/config/sync/antibot.settings.yml @@ -0,0 +1,12 @@ +form_ids: + - comment_comment_form + - user_login_form + - user_pass + - user_register_form + - contact_message_feedback_form + - contact_message_personal_form + - webform-submission-training-node-58-add-form + - webform-submission-contact-node-163-add-form +show_form_ids: 1 +_core: + default_config_hash: f8-7hVX66ftHnUweoB4XDVx8q1hEr4PiqFvPvFB6yRc diff --git a/config/sync/config_snapshot.snapshot.config_sync.module.antibot.yml b/config/sync/config_snapshot.snapshot.config_sync.module.antibot.yml new file mode 100644 index 0000000..7c942bb --- /dev/null +++ b/config/sync/config_snapshot.snapshot.config_sync.module.antibot.yml @@ -0,0 +1,23 @@ +uuid: 8d3537a1-c75d-47f2-9d56-398adc51fb6f +langcode: en +status: true +dependencies: + module: + - antibot +id: config_sync.module.antibot +snapshotSet: config_sync +extensionType: module +extensionName: antibot +items: + - + collection: '' + name: antibot.settings + data: + form_ids: + - comment_comment_form + - user_login_form + - user_pass + - user_register_form + - contact_message_feedback_form + - contact_message_personal_form + show_form_ids: false diff --git a/config/sync/core.extension.yml b/config/sync/core.extension.yml index 3121656..3729a3b 100644 --- a/config/sync/core.extension.yml +++ b/config/sync/core.extension.yml @@ -5,6 +5,7 @@ module: admin_toolbar_tools: 0 agaric_migration: 0 allowed_formats: 0 + antibot: 0 automated_cron: 0 better_normalizers: 0 block: 0 diff --git a/config/sync/webform.webform.contact.yml b/config/sync/webform.webform.contact.yml index 6cf254f..146abc3 100644 --- a/config/sync/webform.webform.contact.yml +++ b/config/sync/webform.webform.contact.yml @@ -99,7 +99,7 @@ settings: draft_loaded_message: '' confirmation_type: url_message confirmation_title: '' - confirmation_message: 'Your message has been sent.' + confirmation_message: 'Thanks for reaching out! We'll get back to you as soon as one of us (probably Clayton) checks our email.' confirmation_url: '' confirmation_attributes: { } confirmation_back: true @@ -172,40 +172,6 @@ access: users: { } permissions: { } handlers: - email_confirmation: - id: email - label: 'Email confirmation' - handler_id: email_confirmation - status: true - conditions: { } - weight: 1 - settings: - states: - - completed - to_mail: '[webform_submission:values:email:raw]' - to_options: { } - cc_mail: '' - cc_options: { } - bcc_mail: '' - bcc_options: { } - from_mail: _default - from_options: { } - from_name: _default - subject: '[webform_submission:values:subject:raw]' - body: '[webform_submission:values:message:value]' - excluded_elements: { } - ignore_access: false - exclude_empty: true - exclude_empty_checkbox: false - html: true - attachments: false - twig: false - theme_name: '' - debug: false - reply_to: '' - return_path: '' - sender_mail: '' - sender_name: '' email_notification: id: email label: 'Email notification' @@ -226,14 +192,14 @@ handlers: from_options: { } from_name: '[webform_submission:values:name:raw]' subject: '[webform_submission:values:subject:raw]' - body: '[webform_submission:values:message:value]' + body: "Hi Agarics, \r\n\r\nYou got some fan mail.\r\n\r\nSincerely,\r\nAgaric Bot\r\n\r\n

Submitted on {{ webform_token('[webform_submission:created]', webform_submission) }}

\r\n

Submitted by: {{ webform_token('[webform_submission:user]', webform_submission) }}

\r\n

Submitted values are:

\r\n{{ webform_token('[webform_submission:values]', webform_submission) }}\r\n" excluded_elements: { } ignore_access: false exclude_empty: true exclude_empty_checkbox: false html: true attachments: false - twig: false + twig: true theme_name: '' debug: false reply_to: ''