1 | "use strict";
|
2 | var __extends = (this && this.__extends) || (function () {
|
3 | var extendStatics = Object.setPrototypeOf ||
|
4 | ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
5 | function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
6 | return function (d, b) {
|
7 | extendStatics(d, b);
|
8 | function __() { this.constructor = d; }
|
9 | d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
10 | };
|
11 | })();
|
12 | Object.defineProperty(exports, "__esModule", { value: true });
|
13 | var React = require("react");
|
14 | var Regions;
|
15 | (function (Regions) {
|
16 | Regions["australia"] = "australia";
|
17 | Regions["brazil"] = "brazil";
|
18 | Regions["default"] = "default";
|
19 | Regions["europe"] = "europe";
|
20 | Regions["germany"] = "germany";
|
21 | Regions["ireland"] = "ireland";
|
22 | Regions["japan"] = "japan";
|
23 | Regions["private"] = "private";
|
24 | Regions["singapore"] = "singapore";
|
25 | Regions["united_states"] = "united-states";
|
26 | })(Regions = exports.Regions || (exports.Regions = {}));
|
27 | var HKFlagIcon = (function (_super) {
|
28 | __extends(HKFlagIcon, _super);
|
29 | function HKFlagIcon() {
|
30 | return _super !== null && _super.apply(this, arguments) || this;
|
31 | }
|
32 | HKFlagIcon.prototype.render = function () {
|
33 | var _a = this.props, className = _a.className, basePath = _a.basePath, region = _a.region;
|
34 | var src = basePath + "region-" + region;
|
35 | return (React.createElement("img", { src: src + ".png", srcSet: src + ".png 1x, " + src + "@2x.png 2x", className: className }));
|
36 | };
|
37 | HKFlagIcon.defaultProps = {
|
38 | basePath: '/static/dist/flags/',
|
39 | className: '',
|
40 | };
|
41 | return HKFlagIcon;
|
42 | }(React.Component));
|
43 | exports.default = HKFlagIcon;
|
44 |
|
\ | No newline at end of file |