1 | "use strict";
|
2 | var __extends = (this && this.__extends) || (function () {
|
3 | var extendStatics = function (d, b) {
|
4 | extendStatics = Object.setPrototypeOf ||
|
5 | ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
6 | function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
7 | return extendStatics(d, b);
|
8 | };
|
9 | return function (d, b) {
|
10 | extendStatics(d, b);
|
11 | function __() { this.constructor = d; }
|
12 | d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
13 | };
|
14 | })();
|
15 | var __importDefault = (this && this.__importDefault) || function (mod) {
|
16 | return (mod && mod.__esModule) ? mod : { "default": mod };
|
17 | };
|
18 | Object.defineProperty(exports, "__esModule", { value: true });
|
19 | var react_1 = __importDefault(require("react"));
|
20 | var polaris_1 = require("@shopify/polaris");
|
21 | var react_compose_1 = __importDefault(require("@shopify/react-compose"));
|
22 | var withFeature_1 = __importDefault(require("../withFeature"));
|
23 | var loading_1 = require("../store/reducers/embeddedApp/loading");
|
24 |
|
25 |
|
26 |
|
27 |
|
28 | var Loading = (function (_super) {
|
29 | __extends(Loading, _super);
|
30 | function Loading() {
|
31 | return _super !== null && _super.apply(this, arguments) || this;
|
32 | }
|
33 | Loading.prototype.render = function () {
|
34 | var isLoading = this.props.store.isLoading;
|
35 | return isLoading ? react_1.default.createElement(polaris_1.Loading, null) : null;
|
36 | };
|
37 | return Loading;
|
38 | }(react_1.default.PureComponent));
|
39 | exports.Loading = Loading;
|
40 |
|
41 |
|
42 |
|
43 |
|
44 | exports.default = react_compose_1.default(withFeature_1.default(loading_1.feature))(Loading);
|