Dialect block configuration
Dialect frontend

This project is not covered by Drupal’s security advisory policy.

Provides common features that are related to the language switcher.

Use cases

Compact display

By default, the Dialect language switcher is displayed as a closed collapsible select with the current language excluded. The template can be easily overridden.
It does not use a select tag but a plain unordered list.

Optionally the default links from the language switcher can be displayed with the language code (EN) as a replacement of the language name (English).

Exclude some languages

In some situations, we may want to temporarily remove some languages while still keeping them enabled on the backend.

The use cases can be:

  • Provide a MVP of the site translated in some languages while preparing translations for other languages.
  • Keep english enabled in the backend while not needing it as a translation language in the frontend.

Redirect a subset of languages to a single node

The main use case is for defining secondary languages on your website without having to translate the whole interface.

It avoids to have the website in a state that will contain untranslated content for:

  • the front page
  • menus
  • terms
  • ...

This subset of languages will be redirect from any path to a single node.

Configuration

  • Install the module then place the 'Language switcher' block that appears in category 'Dialect'.
  • Configure the node in /admin/config/dialect/shared_block_config. The language fallback configuration is done via the block configuration because several instances can be defined and we need to keep a consistent configuration among blocks.

Custom template

The template and default styling can be overridden without having to deal with the cache tags.

If you want to customize styling, think about library overriding.
For styling, just override dialect.module.css.
By default, the dropdown is displayed on click, if you want to display it on hover, think about overriding dialect.js.

Supporting organizations: 

Project information

  • caution Seeking new maintainer
    The current maintainers are looking for new people to take ownership.
  • Module categories: Multilingual
  • Created by colorfield on , updated
  • shield alertThis project is not covered by the security advisory policy.
    Use at your own risk! It may have publicly disclosed vulnerabilities.

Releases