The currently used patch for #3044993: Allow synced Layout default Translations: translating labels and inline blocks has an issue when using domain-based language selection.

$form['translate_layout'] = [
  '#type' => 'link',
  '#title' => $this->t('Translate layout'),
  '#weight' => -9,
  '#attributes' => ['class' => ['button']],
  '#url' => Url::fromUserInput(
    Url::fromRoute('<current>')->toString() . '/translate'
  ),
  '#access' => $is_enabled && $is_translatable,
];

Results in an InvalidArgumentException because Url::fromUserInput() gets an absolute URL as argument. I uploaded a new patch #3044993: Allow synced Layout default Translations: translating labels and inline blocks that fixes this.

Comments

Matthijs created an issue. See original summary.

Matthijs’s picture

Issue summary: View changes

  • Grayle committed a01cd6f on 6.x
    Issue #3267742: Manage display tab broken when using domain-based...
Grayle’s picture

Status: Active » Fixed
Matthijs’s picture

Status: Fixed » Needs work

Some files were missing in my previous patch. Please use this one instead: https://www.drupal.org/files/issues/2022-03-04/allow-synced-default-lb-t...

Grayle’s picture

Status: Needs work » Fixed

Updated patch

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.