@builder.io/sdk 1.2.0 → 1.3.1-0
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/.yarnrc.yml +1 -0
- package/CHANGELOG.md +4 -1
- package/README.md +5 -3
- package/coverage/clover.xml +3848 -0
- package/coverage/coverage-final.json +19 -0
- package/coverage/lcov-report/base.css +224 -0
- package/coverage/lcov-report/block-navigation.js +87 -0
- package/coverage/lcov-report/favicon.png +0 -0
- package/coverage/lcov-report/index.html +176 -0
- package/coverage/lcov-report/prettify.css +1 -0
- package/coverage/lcov-report/prettify.js +2 -0
- package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
- package/coverage/lcov-report/sorter.js +196 -0
- package/coverage/lcov-report/src/builder.class.ts.html +8107 -0
- package/coverage/lcov-report/src/classes/animator.class.ts.html +847 -0
- package/coverage/lcov-report/src/classes/cookies.class.ts.html +559 -0
- package/coverage/lcov-report/src/classes/index.html +176 -0
- package/coverage/lcov-report/src/classes/observable.class.ts.html +388 -0
- package/coverage/lcov-report/src/classes/promise.class.ts.html +607 -0
- package/coverage/lcov-report/src/classes/query-string.class.ts.html +328 -0
- package/coverage/lcov-report/src/functions/assign.function.ts.html +139 -0
- package/coverage/lcov-report/src/functions/fetch.function.ts.html +427 -0
- package/coverage/lcov-report/src/functions/get-top-level-domain.ts.html +121 -0
- package/coverage/lcov-report/src/functions/index.html +236 -0
- package/coverage/lcov-report/src/functions/next-tick.function.ts.html +184 -0
- package/coverage/lcov-report/src/functions/omit.function.ts.html +106 -0
- package/coverage/lcov-report/src/functions/server-only-require.function.ts.html +121 -0
- package/coverage/lcov-report/src/functions/throttle.function.ts.html +181 -0
- package/coverage/lcov-report/src/functions/to-error.ts.html +133 -0
- package/coverage/lcov-report/src/functions/uuid.ts.html +136 -0
- package/coverage/lcov-report/src/index.html +131 -0
- package/coverage/lcov-report/src/polyfills/custom-event-polyfill.js.html +121 -0
- package/coverage/lcov-report/src/polyfills/index.html +116 -0
- package/coverage/lcov-report/src/types/api-version.ts.html +91 -0
- package/coverage/lcov-report/src/types/index.html +116 -0
- package/coverage/lcov-report/src/url.ts.html +253 -0
- package/coverage/lcov.info +4317 -0
- package/dist/index.browser.js +1 -1
- package/dist/index.browser.js.map +1 -1
- package/dist/index.cjs.js +15 -5
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +7 -7
- package/dist/index.esm.js +15 -5
- package/dist/index.esm.js.map +1 -1
- package/dist/index.umd.js +15 -5
- package/dist/index.umd.js.map +1 -1
- package/dist/package.json +3 -7
- package/dist/src/builder.class.d.ts +1 -0
- package/dist/src/builder.class.js +13 -3
- package/dist/src/builder.class.js.map +1 -1
- package/dist/src/builder.class.test.d.ts +1 -0
- package/dist/src/builder.class.test.js +23 -0
- package/dist/src/builder.class.test.js.map +1 -0
- package/dist/src/classes/animator.class.d.ts +26 -26
- package/dist/src/classes/promise.class.d.ts +17 -17
- package/dist/src/classes/query-string.class.d.ts +9 -9
- package/dist/src/classes/query-string.class.test.d.ts +1 -1
- package/dist/src/constants/builder.d.ts +2 -2
- package/dist/src/functions/assign.function.d.ts +1 -1
- package/dist/src/functions/fetch.function.d.ts +28 -28
- package/dist/src/functions/finder.function.d.ts +10 -10
- package/dist/src/functions/get-top-level-domain.d.ts +6 -6
- package/dist/src/functions/omit.function.d.ts +1 -1
- package/dist/src/functions/throttle.function.d.ts +1 -1
- package/dist/src/functions/to-error.d.ts +13 -13
- package/dist/src/functions/uuid.d.ts +8 -8
- package/dist/src/types/api-version.d.ts +2 -2
- package/dist/src/types/api-version.js +1 -1
- package/dist/src/types/content.d.ts +31 -31
- package/dist/src/types/element.d.ts +60 -60
- package/dist/src/url.test.d.ts +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/jest.config.ts +1 -3
- package/package.json +4 -8
package/dist/index.umd.js
CHANGED
|
@@ -152,7 +152,7 @@
|
|
|
152
152
|
throw new Error("Property name \"".concat(name, "\" is not allowed"));
|
|
153
153
|
}
|
|
154
154
|
|
|
155
|
-
var version = "1.1
|
|
155
|
+
var version = "1.3.1-0";
|
|
156
156
|
|
|
157
157
|
var Subscription = /** @class */ (function () {
|
|
158
158
|
function Subscription(listeners, listener) {
|
|
@@ -1060,7 +1060,7 @@
|
|
|
1060
1060
|
return new Error(String(err));
|
|
1061
1061
|
}
|
|
1062
1062
|
|
|
1063
|
-
var DEFAULT_API_VERSION = '
|
|
1063
|
+
var DEFAULT_API_VERSION = 'v1';
|
|
1064
1064
|
|
|
1065
1065
|
function datePlusMinutes(minutes) {
|
|
1066
1066
|
if (minutes === void 0) { minutes = 30; }
|
|
@@ -1363,7 +1363,11 @@
|
|
|
1363
1363
|
this.trustedHosts.push(host);
|
|
1364
1364
|
};
|
|
1365
1365
|
Builder.isTrustedHost = function (hostname) {
|
|
1366
|
-
return (this.trustedHosts.findIndex(function (trustedHost) {
|
|
1366
|
+
return (this.trustedHosts.findIndex(function (trustedHost) {
|
|
1367
|
+
return trustedHost.startsWith('*.')
|
|
1368
|
+
? hostname.endsWith(trustedHost.slice(1))
|
|
1369
|
+
: trustedHost === hostname;
|
|
1370
|
+
}) > -1);
|
|
1367
1371
|
};
|
|
1368
1372
|
Builder.runAction = function (action) {
|
|
1369
1373
|
// TODO
|
|
@@ -2625,7 +2629,7 @@
|
|
|
2625
2629
|
if (options === void 0) { options = {}; }
|
|
2626
2630
|
var instance = this;
|
|
2627
2631
|
if (!Builder.isBrowser) {
|
|
2628
|
-
instance = new Builder(options.apiKey || this.apiKey, options.req, options.res, false, null, options.apiVersion);
|
|
2632
|
+
instance = new Builder(options.apiKey || this.apiKey, options.req, options.res, false, null, options.apiVersion || this.apiVersion);
|
|
2629
2633
|
instance.setUserAttributes(this.getUserAttributes());
|
|
2630
2634
|
}
|
|
2631
2635
|
else {
|
|
@@ -2665,7 +2669,13 @@
|
|
|
2665
2669
|
Builder.nextTick = nextTick;
|
|
2666
2670
|
Builder.throttle = throttle;
|
|
2667
2671
|
Builder.editors = [];
|
|
2668
|
-
Builder.trustedHosts = [
|
|
2672
|
+
Builder.trustedHosts = [
|
|
2673
|
+
'*.beta.builder.io',
|
|
2674
|
+
'beta.builder.io',
|
|
2675
|
+
'builder.io',
|
|
2676
|
+
'localhost',
|
|
2677
|
+
'qa.builder.io',
|
|
2678
|
+
];
|
|
2669
2679
|
Builder.plugins = [];
|
|
2670
2680
|
Builder.actions = [];
|
|
2671
2681
|
Builder.registry = {};
|