title: Contact
description: 'Basic email contact webform.'
elements: |
  name:
    '#title': 'Your Name'
    '#type': textfield
    '#required': true
    '#default_value': '[current-user:display-name]'
  email:
    '#title': 'Your Email'
    '#type': email
    '#required': true
    '#default_value': '[current-user:mail]'
  subject:
    '#title': Subject
    '#type': textfield
    '#required': true
    '#test': 'Testing contact webform from [site:name]'
  message:
    '#title': Message
    '#type': textarea
    '#required': true
    '#test': 'Please ignore this email.'
  actions:
    '#type': webform_actions
    '#title': 'Submit button(s)'
    '#submit__label': 'Send message'
settings:
  confirmation_message: 'Your message has been sent.'
  confirmation_url: '<front>'
handlers:
  email_confirmation:
    label: 'Email confirmation'
    settings:
      from_name: _default
      subject: '[webform_submission:values:subject:raw]'
      body: '[webform_submission:values:message:value]'
  email_notification:
    label: 'Email notification'
    settings:
      from_name: '[webform_submission:values:name:raw]'
      subject: '[webform_submission:values:subject:raw]'
      body: '[webform_submission:values:message:value]'
