Problem/Motivation

In addition to the menu translations we have a use case where we needed the Translatable menu link uri module to translate paths that are not internal. This is a functionality that isn't in core, but makes menus more flexible. Don't know if it's a great addition for the graphql compose module, but I provide the patch anyways for people that demand the same functionality.

Steps to reproduce

Add a menulink item with a external url, and translate this url.

Proposed resolution

You should get the translated external urls, whilst still getting the internal urls for menu items that have internal nodes referenced.

CommentFileSizeAuthor
translatable-menu-link-uri.patch4.38 KBcedricl
Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

CedricL created an issue. See original summary.

almunnings’s picture

Yeah we can support this, I'll re-roll this patch into 2.1.x-dev and take the SDL deprecation into consideration,

almunnings’s picture

Status: Needs review » Needs work

almunnings’s picture

Hiding your patch, as it wont apply to 2.1-dev anymore.

Rerolled in MR:
Same-same but wrapped up into a buffer for the entity load by uuid.
Might make the performance better for you on larger sites.

almunnings’s picture

Status: Needs work » Needs review
almunnings’s picture

Status: Needs review » Fixed

In 2.1 beta 1, thanks

almunnings’s picture

Status: Fixed » Closed (fixed)