Problem/Motivation

The current state of the module only supports the following paramaters provided by the DeepL API

  • text
  • source_lang
  • target_lang

Remaining tasks

The options mentioned above should be extended by all possible parameters provided by the DeepL API

  • tag_handling
  • non_splitting_tags
  • ignore_tags
  • split_sentences
  • preserve_formatting

Afterwards the DeeplProTranslator doRequest method has to be updated to use those parameters.

CommentFileSizeAuthor
#2 2982371-add-more-options-1.patch5.25 KBcyberschorsch

Comments

SteffenR created an issue. See original summary.

cyberschorsch’s picture

Version: » 8.x-1.x-dev
Status: Active » Needs review
StatusFileSize
new5.25 KB

I added the options provided by deepl and also added them to the request. I also changed the request to send the query parameters with the POST body instead of being actual query parameters as in a get request.

cyberschorsch’s picture

This might also fix https://www.drupal.org/project/tmgmt_deepl/issues/2982375 as tag_handling should fix markup handling.

  • SteffenR committed 96eb13b on 8.x-1.x
    #2982371: add more config options for DeeplProTranslator / updated...

steffenr’s picture

@Cyberschorsch: Thanks for your patch. I added the changes to the latest DEV release and changed the field widget/ schema for the settings split_sentences and preserve_formatting. Those fields should be select fields to enable/ disable those options.

The Tag-Handling issue described in #2982375: Markup issues in translated content was also fixed by adding xml to the option tag_handling.

Great work!

steffenr’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

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