a zip code crypto-currency system good for red ONLY

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  1. (function (factory) {
  2. if (typeof module === "object" && typeof module.exports === "object") {
  3. var v = factory(require, exports);
  4. if (v !== undefined) module.exports = v;
  5. }
  6. else if (typeof define === "function" && define.amd) {
  7. define(["require", "exports", "@angular/core"], factory);
  8. }
  9. })(function (require, exports) {
  10. "use strict";
  11. Object.defineProperty(exports, "__esModule", { value: true });
  12. var core_1 = require("@angular/core");
  13. /**
  14. * Base class for all Ionic components. Exposes some common functionality
  15. * that all Ionic components need, such as accessing underlying native elements and
  16. * sending/receiving app-level events.
  17. */
  18. /** @hidden */
  19. var Ion = (function () {
  20. function Ion(config, elementRef, renderer, componentName) {
  21. this._config = config;
  22. this._elementRef = elementRef;
  23. this._renderer = renderer;
  24. this._componentName = componentName;
  25. if (componentName) {
  26. this._setComponentName();
  27. this._setMode(config.get('mode'));
  28. }
  29. }
  30. Object.defineProperty(Ion.prototype, "color", {
  31. get: function () {
  32. return this._color;
  33. },
  34. /**
  35. * @input {string} The color to use from your Sass `$colors` map.
  36. * Default options are: `"primary"`, `"secondary"`, `"danger"`, `"light"`, and `"dark"`.
  37. * For more information, see [Theming your App](/docs/theming/theming-your-app).
  38. */
  39. set: function (val) {
  40. this._setColor(val);
  41. },
  42. enumerable: true,
  43. configurable: true
  44. });
  45. Object.defineProperty(Ion.prototype, "mode", {
  46. get: function () {
  47. return this._mode;
  48. },
  49. /**
  50. * @input {string} The mode determines which platform styles to use.
  51. * Possible values are: `"ios"`, `"md"`, or `"wp"`.
  52. * For more information, see [Platform Styles](/docs/theming/platform-specific-styles).
  53. */
  54. set: function (val) {
  55. this._setMode(val);
  56. },
  57. enumerable: true,
  58. configurable: true
  59. });
  60. /** @hidden */
  61. Ion.prototype.setElementClass = function (className, isAdd) {
  62. this._renderer.setElementClass(this._elementRef.nativeElement, className, isAdd);
  63. };
  64. /** @hidden */
  65. Ion.prototype.setElementAttribute = function (attributeName, attributeValue) {
  66. this._renderer.setElementAttribute(this._elementRef.nativeElement, attributeName, attributeValue);
  67. };
  68. /** @hidden */
  69. Ion.prototype.setElementStyle = function (property, value) {
  70. this._renderer.setElementStyle(this._elementRef.nativeElement, property, value);
  71. };
  72. /** @hidden */
  73. Ion.prototype._setColor = function (newColor, componentName) {
  74. if (componentName) {
  75. // This is needed for the item-radio
  76. this._componentName = componentName;
  77. }
  78. if (this._color) {
  79. this.setElementClass(this._componentName + "-" + this._mode + "-" + this._color, false);
  80. }
  81. if (newColor) {
  82. this.setElementClass(this._componentName + "-" + this._mode + "-" + newColor, true);
  83. this._color = newColor;
  84. }
  85. };
  86. /** @hidden */
  87. Ion.prototype._setMode = function (newMode) {
  88. if (this._mode) {
  89. this.setElementClass(this._componentName + "-" + this._mode, false);
  90. }
  91. if (newMode) {
  92. this.setElementClass(this._componentName + "-" + newMode, true);
  93. // Remove the color class associated with the previous mode,
  94. // change the mode, then add the new color class
  95. this._setColor(null);
  96. this._mode = newMode;
  97. this._setColor(this._color);
  98. }
  99. };
  100. /** @hidden */
  101. Ion.prototype._setComponentName = function () {
  102. this.setElementClass(this._componentName, true);
  103. };
  104. /** @hidden */
  105. Ion.prototype.getElementRef = function () {
  106. return this._elementRef;
  107. };
  108. /** @hidden */
  109. Ion.prototype.getNativeElement = function () {
  110. return this._elementRef.nativeElement;
  111. };
  112. Ion.propDecorators = {
  113. 'color': [{ type: core_1.Input },],
  114. 'mode': [{ type: core_1.Input },],
  115. };
  116. return Ion;
  117. }());
  118. exports.Ion = Ion;
  119. });
  120. //# sourceMappingURL=ion.js.map