@plasmicpkgs/commerce 0.0.27 → 0.0.30
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/commerce.cjs.development.js +22 -21
- package/dist/commerce.cjs.development.js.map +1 -1
- package/dist/commerce.cjs.production.min.js +1 -1
- package/dist/commerce.cjs.production.min.js.map +1 -1
- package/dist/commerce.esm.js +22 -21
- package/dist/commerce.esm.js.map +1 -1
- package/dist/registerCart.d.ts +1 -0
- package/dist/registerCategoryField.d.ts +1 -0
- package/dist/registerCategoryMedia.d.ts +1 -0
- package/dist/registerProductMedia.d.ts +1 -0
- package/dist/registerProductPrice.d.ts +1 -0
- package/dist/registerProductTextField.d.ts +1 -0
- package/dist/registerProductVariantPicker.d.ts +1 -0
- package/dist/utils/use-data.d.ts +4 -4
- package/package.json +4 -3
|
@@ -8,7 +8,7 @@ var registerComponent = _interopDefault(require('@plasmicapp/host/registerCompon
|
|
|
8
8
|
var React = require('react');
|
|
9
9
|
var React__default = _interopDefault(React);
|
|
10
10
|
var reactHookForm = require('react-hook-form');
|
|
11
|
-
var
|
|
11
|
+
var query = require('@plasmicapp/query');
|
|
12
12
|
var Cookies = _interopDefault(require('js-cookie'));
|
|
13
13
|
var host = require('@plasmicapp/host');
|
|
14
14
|
|
|
@@ -307,11 +307,9 @@ var runtime_1 = /*#__PURE__*/createCommonjsModule(function (module) {
|
|
|
307
307
|
|
|
308
308
|
|
|
309
309
|
var IteratorPrototype = {};
|
|
310
|
-
|
|
311
|
-
IteratorPrototype[iteratorSymbol] = function () {
|
|
310
|
+
define(IteratorPrototype, iteratorSymbol, function () {
|
|
312
311
|
return this;
|
|
313
|
-
};
|
|
314
|
-
|
|
312
|
+
});
|
|
315
313
|
var getProto = Object.getPrototypeOf;
|
|
316
314
|
var NativeIteratorPrototype = getProto && getProto(getProto(values([])));
|
|
317
315
|
|
|
@@ -322,8 +320,9 @@ var runtime_1 = /*#__PURE__*/createCommonjsModule(function (module) {
|
|
|
322
320
|
}
|
|
323
321
|
|
|
324
322
|
var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype);
|
|
325
|
-
GeneratorFunction.prototype =
|
|
326
|
-
|
|
323
|
+
GeneratorFunction.prototype = GeneratorFunctionPrototype;
|
|
324
|
+
define(Gp, "constructor", GeneratorFunctionPrototype);
|
|
325
|
+
define(GeneratorFunctionPrototype, "constructor", GeneratorFunction);
|
|
327
326
|
GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"); // Helper for defining the .next, .throw, and .return methods of the
|
|
328
327
|
// Iterator interface in terms of a single ._invoke method.
|
|
329
328
|
|
|
@@ -428,11 +427,9 @@ var runtime_1 = /*#__PURE__*/createCommonjsModule(function (module) {
|
|
|
428
427
|
}
|
|
429
428
|
|
|
430
429
|
defineIteratorMethods(AsyncIterator.prototype);
|
|
431
|
-
|
|
432
|
-
AsyncIterator.prototype[asyncIteratorSymbol] = function () {
|
|
430
|
+
define(AsyncIterator.prototype, asyncIteratorSymbol, function () {
|
|
433
431
|
return this;
|
|
434
|
-
};
|
|
435
|
-
|
|
432
|
+
});
|
|
436
433
|
exports.AsyncIterator = AsyncIterator; // Note that simple async functions are implemented on top of
|
|
437
434
|
// AsyncIterator objects; they just return a Promise for the value of
|
|
438
435
|
// the final result produced by the iterator.
|
|
@@ -609,13 +606,12 @@ var runtime_1 = /*#__PURE__*/createCommonjsModule(function (module) {
|
|
|
609
606
|
// object to not be returned from this call. This ensures that doesn't happen.
|
|
610
607
|
// See https://github.com/facebook/regenerator/issues/274 for more details.
|
|
611
608
|
|
|
612
|
-
Gp
|
|
609
|
+
define(Gp, iteratorSymbol, function () {
|
|
613
610
|
return this;
|
|
614
|
-
};
|
|
615
|
-
|
|
616
|
-
Gp.toString = function () {
|
|
611
|
+
});
|
|
612
|
+
define(Gp, "toString", function () {
|
|
617
613
|
return "[object Generator]";
|
|
618
|
-
};
|
|
614
|
+
});
|
|
619
615
|
|
|
620
616
|
function pushTryEntry(locs) {
|
|
621
617
|
var entry = {
|
|
@@ -927,14 +923,19 @@ var runtime_1 = /*#__PURE__*/createCommonjsModule(function (module) {
|
|
|
927
923
|
} catch (accidentalStrictMode) {
|
|
928
924
|
// This module should not be running in strict mode, so the above
|
|
929
925
|
// assignment should always work unless something is misconfigured. Just
|
|
930
|
-
// in case runtime.js accidentally runs in strict mode,
|
|
926
|
+
// in case runtime.js accidentally runs in strict mode, in modern engines
|
|
927
|
+
// we can explicitly access globalThis. In older engines we can escape
|
|
931
928
|
// strict mode using a global Function call. This could conceivably fail
|
|
932
929
|
// if a Content Security Policy forbids using Function, but in that case
|
|
933
930
|
// the proper solution is to fix the accidental strict mode problem. If
|
|
934
931
|
// you've misconfigured your bundler to force strict mode and applied a
|
|
935
932
|
// CSP to forbid Function, and you're not willing to fix either of those
|
|
936
933
|
// problems, please detail your unique predicament in a GitHub issue.
|
|
937
|
-
|
|
934
|
+
if (typeof globalThis === "object") {
|
|
935
|
+
globalThis.regeneratorRuntime = runtime;
|
|
936
|
+
} else {
|
|
937
|
+
Function("r", "regeneratorRuntime = r")(runtime);
|
|
938
|
+
}
|
|
938
939
|
}
|
|
939
940
|
});
|
|
940
941
|
|
|
@@ -1177,15 +1178,15 @@ var useData = function useData(options, input, fetcherFn, swrOptions) {
|
|
|
1177
1178
|
};
|
|
1178
1179
|
}();
|
|
1179
1180
|
|
|
1180
|
-
var response =
|
|
1181
|
+
var response = query.useMutablePlasmicQueryData(function () {
|
|
1181
1182
|
var opts = options.fetchOptions;
|
|
1182
1183
|
return opts ? [opts.url, opts.query, opts.method].concat(hookInput.map(function (e) {
|
|
1183
1184
|
return e[1];
|
|
1184
1185
|
})) : null;
|
|
1185
1186
|
}, fetcher, swrOptions);
|
|
1186
1187
|
|
|
1187
|
-
if (!(
|
|
1188
|
-
defineProperty(response,
|
|
1188
|
+
if (!("isLoading" in response)) {
|
|
1189
|
+
defineProperty(response, "isLoading", {
|
|
1189
1190
|
get: function get() {
|
|
1190
1191
|
return response.data === undefined;
|
|
1191
1192
|
},
|