-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #259 from Bixal/feature/BSD-258-contact-recaptcha
BSD fixes #258: Remove contact form from bottom, add as menu item.
- Loading branch information
Showing
10 changed files
with
80 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,9 @@ | ||
_core: | ||
default_config_hash: jdY7AU0tU-QsjmiOw3W8vwpYMb-By--_MSFgbqKUTYM | ||
definitions: { } | ||
definitions: | ||
contact__site_page: | ||
enabled: true | ||
menu_name: footer | ||
parent: '' | ||
expanded: false | ||
weight: 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -116,6 +116,9 @@ h6 { | |
margin: 14px 0; | ||
padding: 0 10px; | ||
text-transform: uppercase; | ||
h1 { | ||
all: unset; | ||
} | ||
} | ||
|
||
dl { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
name: 'Bixal Captcha' | ||
type: module | ||
description: 'Alters captcha functionality.' | ||
package: Custom | ||
core_version_requirement: ^10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<?php | ||
|
||
/** | ||
* @file | ||
* Primary module hooks for Bixal Captcha module. | ||
*/ | ||
|
||
/** | ||
* Implements hook_captcha_alter(). | ||
*/ | ||
function bixal_captcha_captcha_alter(&$captcha, $info) { | ||
// If the captcha is cacheable and the env variable is not set to enable | ||
// caching for these, turn off caching. reCaptcha was not working with | ||
// caching on. | ||
if (!getenv('CAPTCHA_ALLOW_CACHEABLE') && ($captcha['cacheable'] ?? FALSE) === TRUE) { | ||
$captcha['form']['#cache']['max-age'] = 0; | ||
\Drupal::service('page_cache_kill_switch')->trigger(); | ||
} | ||
} |
33 changes: 33 additions & 0 deletions
33
.../bixal_default_content/content/menu_link_content/e82e4e98-8db6-4dea-9295-e67608b5ef07.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
_meta: | ||
version: '1.0' | ||
entity_type: menu_link_content | ||
uuid: e82e4e98-8db6-4dea-9295-e67608b5ef07 | ||
bundle: menu_link_content | ||
default_langcode: en | ||
default: | ||
enabled: | ||
- | ||
value: true | ||
title: | ||
- | ||
value: Contact | ||
menu_name: | ||
- | ||
value: main | ||
link: | ||
- | ||
uri: 'internal:/contact' | ||
title: '' | ||
options: { } | ||
external: | ||
- | ||
value: false | ||
rediscover: | ||
- | ||
value: true | ||
weight: | ||
- | ||
value: 0 | ||
expanded: | ||
- | ||
value: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters