Skip to content

Commit

Permalink
Backport lost tinymce translations (#930)
Browse files Browse the repository at this point in the history
* Restore translations of 'Remove link'

* Add missing translationa in tinymce pattern by...

    copying generateModalHtml function from master branch,
    also some backported xml changes from 71ddf6f

* Add 2 further missing translations in tinymce pattern
  • Loading branch information
djowett-ftw authored and vincentfretin committed Jun 24, 2020
1 parent a6fa639 commit ad2773a
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 4 deletions.
4 changes: 3 additions & 1 deletion mockup/patterns/tinymce/js/links.js
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ define([

editor.addButton('unlink', {
icon: 'unlink',
tooltip: 'Remove link(s)',
tooltip: 'Remove link',
cmd: 'unlink',
stateSelector: 'a[href]'
});
Expand Down Expand Up @@ -472,6 +472,8 @@ define([
internal: this.options.text.internal,
external: this.options.text.external,
anchor: this.options.text.anchor,
anchorLabel: this.options.text.anchorLabel,
target: this.options.text.target,
linkTypes: this.options.linkTypes,
externalText: this.options.text.external,
emailText: this.options.text.email,
Expand Down
2 changes: 2 additions & 0 deletions mockup/patterns/tinymce/pattern.js
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,8 @@ define([
externalText: _t('External URL (can be relative within this site or absolute if it starts with http:// or https://)'),
email: _t('Email Address'),
anchor: _t('Anchor'),
anchorLabel: _t('Select an anchor'),
target: _t('Target'),
subject: _t('Email Subject (optional)'),
image: _t('Image'),
imageAlign: _t('Align'),
Expand Down
6 changes: 3 additions & 3 deletions mockup/patterns/tinymce/templates/link.xml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@

<% if(_.contains(linkTypes, 'email')){ %>
<fieldset class="linkType email" data-linkType="email">
<legend id="tinylink-email">Email</legend>
<legend id="tinylink-email"><%- emailText %></legend>
<div class="form-inline">
<div class="form-group main">
<label><%- emailText %></label>
Expand All @@ -58,7 +58,7 @@
<legend id="tinylink-anchor"><%- anchor %></legend>
<div>
<div class="form-group main">
<label>Select an anchor</label>
<label><%- anchorLabel %></label>
<div class="input-wrapper">
<select name="anchor" class="pat-select2" data-pat-select2="width:500px" />
</div>
Expand All @@ -71,7 +71,7 @@

<div class="common-controls">
<div class="form-group">
<label>Target</label>
<label><%- target %></label>
<select name="target">
<% _.each(targetList, function(target){ %>
<option value="<%- target.value %>"><%- target.text %></option>
Expand Down
5 changes: 5 additions & 0 deletions news/910.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
tinymce pattern: Add missing translations by...
- copying generateModalHtml function from master branch,
- adding some backported xml changes from 71ddf6f387
- adding 2 further translations (not yet in master)
[djowett-ftw]

0 comments on commit ad2773a

Please sign in to comment.