a zip code crypto-currency system good for red ONLY

select-popover-component.js 2.5KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  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", "../../navigation/nav-params", "../../navigation/view-controller"], factory);
  8. }
  9. })(function (require, exports) {
  10. "use strict";
  11. Object.defineProperty(exports, "__esModule", { value: true });
  12. var core_1 = require("@angular/core");
  13. var nav_params_1 = require("../../navigation/nav-params");
  14. var view_controller_1 = require("../../navigation/view-controller");
  15. /** @hidden */
  16. var SelectPopover = (function () {
  17. function SelectPopover(navParams, viewController) {
  18. this.navParams = navParams;
  19. this.viewController = viewController;
  20. }
  21. Object.defineProperty(SelectPopover.prototype, "value", {
  22. get: function () {
  23. var checkedOption = this.options.find(function (option) { return option.checked; });
  24. return checkedOption ? checkedOption.value : undefined;
  25. },
  26. set: function (value) {
  27. var checkedOption = this.options.find(function (option) { return option.value === value; });
  28. if (checkedOption && checkedOption.handler) {
  29. checkedOption.handler();
  30. }
  31. this.viewController.dismiss(value);
  32. },
  33. enumerable: true,
  34. configurable: true
  35. });
  36. SelectPopover.prototype.ngOnInit = function () {
  37. this.options = this.navParams.data.options;
  38. };
  39. SelectPopover.decorators = [
  40. { type: core_1.Component, args: [{
  41. template: "\n <ion-list radio-group [(ngModel)]=\"value\">\n <ion-item *ngFor=\"let option of options\">\n <ion-label>{{option.text}}</ion-label>\n <ion-radio [checked]=\"option.checked\" [value]=\"option.value\" [disabled]=\"option.disabled\"></ion-radio>\n </ion-item>\n </ion-list>\n "
  42. },] },
  43. ];
  44. /** @nocollapse */
  45. SelectPopover.ctorParameters = function () { return [
  46. { type: nav_params_1.NavParams, },
  47. { type: view_controller_1.ViewController, },
  48. ]; };
  49. return SelectPopover;
  50. }());
  51. exports.SelectPopover = SelectPopover;
  52. });
  53. //# sourceMappingURL=select-popover-component.js.map