id: d7_theme_settings
label: D7 theme settings
migration_tags:
  - Drupal 7
  - Configuration
source:
  plugin: d7_theme_settings
  constants:
    config_suffix: '.settings'
process:
  # Build the configuration name from the variable name, i.e.
  # theme_bartik_settings becomes bartik.settings.
  legacy_theme_name:
    -
      plugin: explode
      source: name
      delimiter: _
    -
      plugin: extract
      index:
        - 1
  theme_name:
    plugin: static_map
    source: '@legacy_theme_name'
    bypass: true
    map:
      bartik: olivero
      seven: claro
  configuration_name:
    plugin: concat
    source:
      - '@theme_name'
      - constants/config_suffix
  toggle_logo: theme_settings/toggle_logo
  toggle_name: value/toggle_name
  toggle_slogan: value/toggle_slogan
  toggle_node_user_picture: value/toggle_node_user_picture
  toggle_comment_user_picture: value/toggle_comment_user_picture
  toggle_comment_user_verification: value/toggle_comment_user_verification
  toggle_favicon: value/toggle_favicon
  default_logo: value/default_logo
  logo_path: value/logo_path
  logo_upload: value/logo_upload
  default_favicon: value/default_favicon
  favicon_path: value/favicon_path
  favicon_mimetype: value/favicon_mimetype
# Ignore settings not present in Drupal 8.
#  value/favicon_upload
#  value/toggle_main_menu
#  value/toggle_secondary_menu
destination:
  plugin: d7_theme_settings
