locizify 6.0.7 → 6.0.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/CHANGELOG.md +8 -0
- package/README.md +11 -2
- package/dist/umd/locizify.js +36 -36
- package/dist/umd/locizify.min.js +2 -2
- package/locizify.js +36 -36
- package/locizify.min.js +2 -2
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
[](https://travis-ci.org/locize/locizify)
|
|
2
1
|
[](https://coveralls.io/github/locize/locizify)
|
|
3
2
|
[](https://www.npmjs.com/package/locizify)
|
|
4
3
|
|
|
@@ -13,9 +12,19 @@ Just drop the following line to your header to deliver your content in any langu
|
|
|
13
12
|
id="locizify"
|
|
14
13
|
projectid="[PROJECT_ID]"
|
|
15
14
|
apikey="[API_KEY]"
|
|
16
|
-
src="https://unpkg.com/locizify@^
|
|
15
|
+
src="https://unpkg.com/locizify@^6.0.7"
|
|
17
16
|
autopilot
|
|
18
17
|
></script>
|
|
18
|
+
|
|
19
|
+
<!-- or -->
|
|
20
|
+
<script
|
|
21
|
+
id="locizify"
|
|
22
|
+
projectid="[PROJECT_ID]"
|
|
23
|
+
apikey="[API_KEY]"
|
|
24
|
+
src="https://cdn.jsdelivr.net/npm/locizify@^6.0.7"
|
|
25
|
+
autopilot
|
|
26
|
+
></script>
|
|
27
|
+
|
|
19
28
|
```
|
|
20
29
|
|
|
21
30
|
Checkout this [video](https://youtu.be/f0ukRI0LMfo?t=180) to see locizify in action.
|
package/dist/umd/locizify.js
CHANGED
|
@@ -143,45 +143,45 @@
|
|
|
143
143
|
|
|
144
144
|
unwrapExports(_typeof_1);
|
|
145
145
|
|
|
146
|
-
var
|
|
146
|
+
var toPrimitive_1 = createCommonjsModule(function (module) {
|
|
147
147
|
var _typeof = _typeof_1["default"];
|
|
148
148
|
|
|
149
|
-
function
|
|
150
|
-
if (
|
|
151
|
-
var
|
|
149
|
+
function toPrimitive(t, r) {
|
|
150
|
+
if ("object" != _typeof(t) || !t) return t;
|
|
151
|
+
var e = t[Symbol.toPrimitive];
|
|
152
152
|
|
|
153
|
-
if (
|
|
154
|
-
var
|
|
155
|
-
if (
|
|
153
|
+
if (void 0 !== e) {
|
|
154
|
+
var i = e.call(t, r || "default");
|
|
155
|
+
if ("object" != _typeof(i)) return i;
|
|
156
156
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
157
157
|
}
|
|
158
158
|
|
|
159
|
-
return (
|
|
159
|
+
return ("string" === r ? String : Number)(t);
|
|
160
160
|
}
|
|
161
161
|
|
|
162
|
-
module.exports =
|
|
162
|
+
module.exports = toPrimitive, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
163
163
|
});
|
|
164
164
|
|
|
165
|
-
unwrapExports(
|
|
165
|
+
unwrapExports(toPrimitive_1);
|
|
166
166
|
|
|
167
|
-
var
|
|
167
|
+
var toPropertyKey_1 = createCommonjsModule(function (module) {
|
|
168
168
|
var _typeof = _typeof_1["default"];
|
|
169
169
|
|
|
170
170
|
|
|
171
171
|
|
|
172
|
-
function
|
|
173
|
-
var
|
|
174
|
-
return _typeof(
|
|
172
|
+
function toPropertyKey(t) {
|
|
173
|
+
var i = toPrimitive_1(t, "string");
|
|
174
|
+
return "symbol" == _typeof(i) ? i : String(i);
|
|
175
175
|
}
|
|
176
176
|
|
|
177
|
-
module.exports =
|
|
177
|
+
module.exports = toPropertyKey, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
178
178
|
});
|
|
179
179
|
|
|
180
|
-
unwrapExports(
|
|
180
|
+
unwrapExports(toPropertyKey_1);
|
|
181
181
|
|
|
182
182
|
var defineProperty = createCommonjsModule(function (module) {
|
|
183
183
|
function _defineProperty(obj, key, value) {
|
|
184
|
-
key =
|
|
184
|
+
key = toPropertyKey_1(key);
|
|
185
185
|
|
|
186
186
|
if (key in obj) {
|
|
187
187
|
Object.defineProperty(obj, key, {
|
|
@@ -3386,22 +3386,22 @@
|
|
|
3386
3386
|
}, _typeof$3(o);
|
|
3387
3387
|
}
|
|
3388
3388
|
|
|
3389
|
-
function
|
|
3390
|
-
if (_typeof$3(
|
|
3391
|
-
var
|
|
3389
|
+
function toPrimitive(t, r) {
|
|
3390
|
+
if ("object" != _typeof$3(t) || !t) return t;
|
|
3391
|
+
var e = t[Symbol.toPrimitive];
|
|
3392
3392
|
|
|
3393
|
-
if (
|
|
3394
|
-
var
|
|
3395
|
-
if (_typeof$3(
|
|
3393
|
+
if (void 0 !== e) {
|
|
3394
|
+
var i = e.call(t, r || "default");
|
|
3395
|
+
if ("object" != _typeof$3(i)) return i;
|
|
3396
3396
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
3397
3397
|
}
|
|
3398
3398
|
|
|
3399
|
-
return (
|
|
3399
|
+
return ("string" === r ? String : Number)(t);
|
|
3400
3400
|
}
|
|
3401
3401
|
|
|
3402
|
-
function
|
|
3403
|
-
var
|
|
3404
|
-
return _typeof$3(
|
|
3402
|
+
function toPropertyKey(t) {
|
|
3403
|
+
var i = toPrimitive(t, "string");
|
|
3404
|
+
return "symbol" == _typeof$3(i) ? i : String(i);
|
|
3405
3405
|
}
|
|
3406
3406
|
|
|
3407
3407
|
function _defineProperties$1(target, props) {
|
|
@@ -3410,7 +3410,7 @@
|
|
|
3410
3410
|
descriptor.enumerable = descriptor.enumerable || false;
|
|
3411
3411
|
descriptor.configurable = true;
|
|
3412
3412
|
if ("value" in descriptor) descriptor.writable = true;
|
|
3413
|
-
Object.defineProperty(target,
|
|
3413
|
+
Object.defineProperty(target, toPropertyKey(descriptor.key), descriptor);
|
|
3414
3414
|
}
|
|
3415
3415
|
}
|
|
3416
3416
|
|
|
@@ -3863,7 +3863,7 @@
|
|
|
3863
3863
|
descriptor.enumerable = descriptor.enumerable || false;
|
|
3864
3864
|
descriptor.configurable = true;
|
|
3865
3865
|
if ("value" in descriptor) descriptor.writable = true;
|
|
3866
|
-
Object.defineProperty(target,
|
|
3866
|
+
Object.defineProperty(target, toPropertyKey_1(descriptor.key), descriptor);
|
|
3867
3867
|
}
|
|
3868
3868
|
}
|
|
3869
3869
|
|
|
@@ -8618,7 +8618,7 @@
|
|
|
8618
8618
|
descriptor.enumerable = descriptor.enumerable || false;
|
|
8619
8619
|
descriptor.configurable = true;
|
|
8620
8620
|
if ("value" in descriptor) descriptor.writable = true;
|
|
8621
|
-
Object.defineProperty(target, _toPropertyKey$
|
|
8621
|
+
Object.defineProperty(target, _toPropertyKey$1(descriptor.key), descriptor);
|
|
8622
8622
|
}
|
|
8623
8623
|
}
|
|
8624
8624
|
|
|
@@ -8631,13 +8631,13 @@
|
|
|
8631
8631
|
return Constructor;
|
|
8632
8632
|
}
|
|
8633
8633
|
|
|
8634
|
-
function _toPropertyKey$
|
|
8635
|
-
var key = _toPrimitive$
|
|
8634
|
+
function _toPropertyKey$1(arg) {
|
|
8635
|
+
var key = _toPrimitive$1(arg, "string");
|
|
8636
8636
|
|
|
8637
8637
|
return _typeof$5(key) === "symbol" ? key : String(key);
|
|
8638
8638
|
}
|
|
8639
8639
|
|
|
8640
|
-
function _toPrimitive$
|
|
8640
|
+
function _toPrimitive$1(input, hint) {
|
|
8641
8641
|
if (_typeof$5(input) !== "object" || input === null) return input;
|
|
8642
8642
|
var prim = input[Symbol.toPrimitive];
|
|
8643
8643
|
|
|
@@ -9399,7 +9399,7 @@
|
|
|
9399
9399
|
I18NextLocizeBackend.type = 'backend';
|
|
9400
9400
|
|
|
9401
9401
|
function _defineProperty$3(obj, key, value) {
|
|
9402
|
-
key =
|
|
9402
|
+
key = toPropertyKey(key);
|
|
9403
9403
|
|
|
9404
9404
|
if (key in obj) {
|
|
9405
9405
|
Object.defineProperty(obj, key, {
|
|
@@ -12933,7 +12933,7 @@
|
|
|
12933
12933
|
});
|
|
12934
12934
|
},
|
|
12935
12935
|
getLng: function getLng() {
|
|
12936
|
-
return i18n.languages[0];
|
|
12936
|
+
return i18n.resolvedLanguage || i18n.languages[0];
|
|
12937
12937
|
},
|
|
12938
12938
|
getSourceLng: function getSourceLng() {
|
|
12939
12939
|
var fallback = i18n.options.fallbackLng;
|
|
@@ -13008,7 +13008,7 @@
|
|
|
13008
13008
|
|
|
13009
13009
|
if (!isInIframe && showInContext) {
|
|
13010
13010
|
start(impl);
|
|
13011
|
-
} else {
|
|
13011
|
+
} else if (isInIframe) {
|
|
13012
13012
|
startLegacy(impl);
|
|
13013
13013
|
}
|
|
13014
13014
|
}
|