andoncloud-widget-preview 1.1.8 → 1.1.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +9 -1
- package/dist/index.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/package.json +9 -9
package/dist/index.js
CHANGED
|
@@ -1675,6 +1675,7 @@ var Interpolator = function () {
|
|
|
1675
1675
|
while (match = this.nestingRegexp.exec(str)) {
|
|
1676
1676
|
var formatters = [];
|
|
1677
1677
|
clonedOptions = _objectSpread$3({}, options);
|
|
1678
|
+
clonedOptions = clonedOptions.replace && typeof clonedOptions.replace !== 'string' ? clonedOptions.replace : clonedOptions;
|
|
1678
1679
|
clonedOptions.applyPostProcessor = false;
|
|
1679
1680
|
delete clonedOptions.defaultValue;
|
|
1680
1681
|
var doReduce = false;
|
|
@@ -2531,7 +2532,14 @@ var I18n = function (_EventEmitter) {
|
|
|
2531
2532
|
options.ns = options.ns || fixedT.ns;
|
|
2532
2533
|
options.keyPrefix = options.keyPrefix || keyPrefix || fixedT.keyPrefix;
|
|
2533
2534
|
var keySeparator = _this5.options.keySeparator || '.';
|
|
2534
|
-
var resultKey
|
|
2535
|
+
var resultKey;
|
|
2536
|
+
if (options.keyPrefix && Array.isArray(key)) {
|
|
2537
|
+
resultKey = key.map(function (k) {
|
|
2538
|
+
return "".concat(options.keyPrefix).concat(keySeparator).concat(k);
|
|
2539
|
+
});
|
|
2540
|
+
} else {
|
|
2541
|
+
resultKey = options.keyPrefix ? "".concat(options.keyPrefix).concat(keySeparator).concat(key) : key;
|
|
2542
|
+
}
|
|
2535
2543
|
return _this5.t(resultKey, options);
|
|
2536
2544
|
};
|
|
2537
2545
|
if (typeof lng === 'string') {
|