a zip code crypto-currency system good for red ONLY

item-options.js 2.6KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  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", "../../platform/platform", "../../util/util"], 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 platform_1 = require("../../platform/platform");
  14. var util_1 = require("../../util/util");
  15. /**
  16. * @name ItemOptions
  17. * @description
  18. * The option buttons for an `ion-item-sliding`. These buttons can be placed either on the left or right side.
  19. * You can combine the `(ionSwipe)` event plus the `expandable` directive to create a full swipe action for the item.
  20. *
  21. * @usage
  22. *
  23. * ```html
  24. * <ion-item-sliding>
  25. * <ion-item>
  26. * Item 1
  27. * </ion-item>
  28. * <ion-item-options side="right" (ionSwipe)="saveItem(item)">
  29. * <button ion-button expandable (click)="saveItem(item)">
  30. * <ion-icon name="star"></ion-icon>
  31. * </button>
  32. * </ion-item-options>
  33. * </ion-item-sliding>
  34. *```
  35. */
  36. var ItemOptions = (function () {
  37. function ItemOptions(_elementRef, _plt) {
  38. this._elementRef = _elementRef;
  39. this._plt = _plt;
  40. /**
  41. * @output {event} Emitted when the item has been fully swiped.
  42. */
  43. this.ionSwipe = new core_1.EventEmitter();
  44. }
  45. /**
  46. * @hidden
  47. */
  48. ItemOptions.prototype.isRightSide = function () {
  49. return util_1.isRightSide(this.side, this._plt.isRTL, true);
  50. };
  51. /**
  52. * @hidden
  53. */
  54. ItemOptions.prototype.width = function () {
  55. return this._elementRef.nativeElement.offsetWidth;
  56. };
  57. ItemOptions.decorators = [
  58. { type: core_1.Directive, args: [{
  59. selector: 'ion-item-options',
  60. },] },
  61. ];
  62. /** @nocollapse */
  63. ItemOptions.ctorParameters = function () { return [
  64. { type: core_1.ElementRef, },
  65. { type: platform_1.Platform, },
  66. ]; };
  67. ItemOptions.propDecorators = {
  68. 'side': [{ type: core_1.Input },],
  69. 'ionSwipe': [{ type: core_1.Output },],
  70. };
  71. return ItemOptions;
  72. }());
  73. exports.ItemOptions = ItemOptions;
  74. });
  75. //# sourceMappingURL=item-options.js.map