We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 03b1a66 commit 63706e6Copy full SHA for 63706e6
1 file changed
src/assets/print-view/fetch-orcid.js
@@ -3,7 +3,11 @@
3
if (typeof $localize === 'undefined') {
4
self.$localize = function (messageParts) {
5
var substitutions = Array.prototype.slice.call(arguments, 1)
6
- return messageParts.reduce(function (result, part, i) {
+ // Strip Angular localize metadata: `:description@@id:` (first part) or `:PLACEHOLDER:` (rest)
7
+ var parts = Array.prototype.map.call(messageParts, function (part) {
8
+ return typeof part === 'string' ? part.replace(/^:[^:]*:/, '') : part
9
+ })
10
+ return parts.reduce(function (result, part, i) {
11
return (
12
result +
13
(substitutions[i - 1] != null ? substitutions[i - 1] : '') +
0 commit comments