Skip to content
This repository has been archived by the owner on Nov 1, 2023. It is now read-only.

Commit

Permalink
Merge pull request #45 from zischler/develop
Browse files Browse the repository at this point in the history
i18n updates and custom form to vue component
  • Loading branch information
zischler authored Feb 8, 2021
2 parents 40ac719 + a3c352e commit a08e0d2
Show file tree
Hide file tree
Showing 23 changed files with 558 additions and 169 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,82 +4,200 @@ fieldLayouts:
-
elements:
-
autocapitalize: true
autocomplete: false
autocorrect: true
class: null
disabled: false
id: null
instructions: null
label: Title
label: null
max: null
min: null
name: null
orientation: null
placeholder: null
readonly: false
requirable: false
size: null
step: null
tip: null
title: null
type: craft\fieldlayoutelements\EntryTitleField
warning: null
width: 100
-
fieldUid: e4a284e3-2244-492e-89de-7fcbb7e392d8
required: false
type: craft\fieldlayoutelements\CustomField
-
fieldUid: 6027c90e-6bf7-4408-ac4b-5ed40857fc4f
required: true
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: f223541d-0057-4b42-8f60-11587c05dbf9
required: false
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
name: Main
sortOrder: 1
-
elements:
-
fieldUid: 13c6850e-3517-47ef-87e2-e01f728a06d5
required: false
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: 3fd6881a-8adc-40ad-990a-ae8344de3362
required: false
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: aff46670-72d3-4242-baa5-ce06a7dc3952
required: false
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
name: Meta
sortOrder: 2
-
elements:
-
fieldUid: f94cdc90-b38d-4b88-86fd-973ecb58cf62
fieldUid: 6027c90e-6bf7-4408-ac4b-5ed40857fc4f
instructions: null
label: null
required: '1'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: c29135c5-12a9-402c-bbdd-9df2ed2400a3
instructions: null
label: null
required: false
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: 2ad2c7f5-b2bd-4612-a7e0-3eff1f2b7f3a
fieldUid: c407100c-c7bf-4445-a0d1-8ed28872359c
instructions: null
label: null
required: false
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
name: Form
sortOrder: 3
-
elements:
-
fieldUid: f94cdc90-b38d-4b88-86fd-973ecb58cf62
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: 2ad2c7f5-b2bd-4612-a7e0-3eff1f2b7f3a
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: 9c982c7d-2cf8-4aa7-97b3-942a58eae4c3
required: false
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: 2cdb40be-2324-479c-9c81-d9969a8209ad
required: false
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: a113a8b3-4496-4568-a853-5c570df872f5
required: false
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: e5648baf-4d97-4494-979b-83d20590f499
required: false
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: 40704421-15a9-47a3-ae0b-9a493b494ba6
required: false
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: 03dca4c0-2afa-461b-be54-c116b4183458
required: false
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: e6759eb9-e696-415e-b3f3-a4937ef0b486
required: false
instructions: null
label: null
required: '0'
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
name: 'Google Maps'
sortOrder: 3
sortOrder: 4
handle: contact
hasTitleField: true
name: Contact
section: 25fdcba8-77b9-4110-a0e1-ec7a9894321c
sortOrder: 1
titleFormat: '{section.name|raw}'
titleTranslationKeyFormat: null
titleTranslationMethod: site
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
name: Form
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
contentColumnType: text
fieldGroup: 01e54fd7-954a-449d-baee-f11148cbb95d
handle: confirmationMailText
instructions: ''
name: 'Confirmation Mail Text'
searchable: false
settings:
availableTransforms: '*'
availableVolumes: '*'
cleanupHtml: true
columnType: text
configSelectionMode: choose
defaultTransform: ''
manualConfig: ''
purifierConfig: ''
purifyHtml: '1'
redactorConfig: Simple.json
removeEmptyTags: '1'
removeInlineStyles: '1'
removeNbsp: '1'
showHtmlButtonForNonAdmins: ''
showUnpermittedFiles: false
showUnpermittedVolumes: false
uiMode: enlarged
translationKeyFormat: null
translationMethod: language
type: craft\redactor\Field
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
contentColumnType: text
fieldGroup: 01e54fd7-954a-449d-baee-f11148cbb95d
handle: errorMessage
instructions: ''
name: 'Error Message'
searchable: false
settings:
byteLimit: null
charLimit: null
code: ''
columnType: null
initialRows: '4'
multiline: ''
placeholder: 'An error occurred while sending the form, please try again later.'
uiMode: normal
translationKeyFormat: null
translationMethod: language
type: craft\fields\PlainText
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
contentColumnType: text
fieldGroup: 01e54fd7-954a-449d-baee-f11148cbb95d
handle: successMessage
instructions: ''
name: 'Success Message'
searchable: false
settings:
byteLimit: null
charLimit: null
code: ''
columnType: null
initialRows: '4'
multiline: ''
placeholder: 'Your message has been sent'
uiMode: normal
translationKeyFormat: null
translationMethod: language
type: craft\fields\PlainText
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
fieldLayouts:
8dc87168-69b4-4eb0-b36c-9cc3b155033c:
tabs:
-
elements:
-
fieldUid: 114a318e-21fc-4304-a4d9-7b6702c52fa2
instructions: null
label: null
required: false
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
name: Main
sortOrder: 1
handle: email
name: Email
2 changes: 1 addition & 1 deletion craft/config/project/project.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
dateModified: 1612781056
dateModified: 1612792003
email:
fromEmail: $SYSTEM_EMAIL
fromName: $SENDER_NAME
Expand Down
6 changes: 1 addition & 5 deletions craft/templates/_includes/footer.twig
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,7 @@
</div>
<div>

{% if craft.app.language == 'de' %}
<span class="h2">Mehr links</span>
{% else %}
<span class="h2">More links</span>
{% endif %}
<span class="h2">{{ 'footer.moreLinks'|t }}</span>

{% set footerGlobal = craft.app.globals.getSetByHandle('footer') %}
<div class="mt-2 flex is-left">
Expand Down
3 changes: 3 additions & 0 deletions craft/templates/_layout.twig
Original file line number Diff line number Diff line change
Expand Up @@ -136,9 +136,12 @@
<!-- JS -->
<script nomodule src="/webresources/build/legacy/main.js"></script>
<script type="module" src="/webresources/build/module/main.js"></script>
{% set recaptchaKey = getenv('RECAPTCHA_SITE') %}
<script>
// Remove no js class
document.body.classList.remove('no-js');
// Set RecaptchaKey for usage in Custom Form
window.recaptchaKey = '{{ recaptchaKey }}';
</script>
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-********-1"></script>
</body>
Expand Down
7 changes: 3 additions & 4 deletions craft/templates/_mail/confirmation.twig
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
{% set homepage = craft.entries.section('homepage').one() %}
{% set emailGlobal = craft.app.globals.getSetByHandle('email') %}
<div>
{% set confirmationText = homepage["confirmationMailText"] ?? null %}
{% if confirmationText %}
<div>{{ confirmationText }}</div>
{% if emailGlobal.confirmationMailText is defined and emailGlobal.confirmationMailText is not empty %}
<div>{{ emailGlobal.confirmationText }}</div>
{% endif %}
<br>

Expand Down
Loading

0 comments on commit a08e0d2

Please sign in to comment.