Question T15034
Visible to All Users

Tanslation Tab - Remove a translation download action

created a year ago (modified a year ago)

[Ticket cloned from T15025: Hide some icons and find some translations]

I even need to remove download icons from this page, how can i do it? Is there any kind of documentation that could help me find those answers without making a post every time i need to target or change a part of plugin interface to show/hide it or change translation of something in particular that is not present in normal translation?

Greetings

Answers approved by surveyjs Support

created a year ago

Hello Luca,
From what I gather, you wish to remove the Import and Export actions from the Translation tab.
For this, subscribe to the creator.onSurveyInstanceCreated function, check if options.reason equals 'translation_strings', obtain Import and Export actions from the creator.toolbar.actions collection and hide them.

JavaScript
creator.onSurveyInstanceCreated.add((s, o) => { if (o.reason === "translation_strings") { creator.toolbar.actions.filter( (x) => x.id === "svc-translation-import" )[0].visible = false; creator.toolbar.actions.filter( (x) => x.id === "svc-translation-export" )[0].visible = false; } });

Please let me know if you have any further questions.